Announcement

Collapse

Maintenance

The forum could be offline for 30-60 minutes in the very near future for maintenance (said 3pm Pacific). I was behind on getting this notice. I do apologize.
See more
See less

Text in Line Control

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Text in Line Control

    The users manual for PB/DLL 6.0 shows that text can be
    displayed in the line control. The short program below
    has one line control with text, but no text is displayed
    when I run it. Yet, I know that the text is stored by
    the control because I can retrieve it with a CONTROL
    GET TEXT statement. I have searched the forum for some
    leads to the problem, but couldn't find any.

    Can anyone tell me why the text isn't displayed.


    #COMPILE EXE
    #INCLUDE "win32api.inc"

    FUNCTION PBMAIN()AS LONG
    LOCAL hWin AS LONG
    DIALOG NEW 0,"Test Line Control",,,120,100, %WS_SYSMENU TO hWin
    CONTROL ADD LINE, hWin, 100, "Testing", 10, 10, 80, 20, %SS_BLACKFRAMEk
    DIALOG SHOW MODAL hWin
    END FUNCTION

  • #2
    A LINE control with the %SS_BLACKFRAME style does not *display* any text, it is a "graphical" control with a black edge only. It has a text property, but as you have found, it is not "visible".

    Maybe you are actually looking for a FRAME control? (A frame control is also known as a group control). Alternatively, look at using a LABEL control.

    Note that all of these controls are members of the "static" control class, and there are many permutations of the styles, so don't be afraid to experiment.


    -------------
    Lance
    PowerBASIC Support
    ( mailto:[email protected][email protected]</A> )
    Lance
    mailto:[email protected]

    Comment

    Working...
    X