Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Toolbar button names
Message
 
 
To
26/11/1997 08:33:10
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00062207
Message ID:
00062375
Views:
34
>>>Where did you find the names of those few? What example?
>>>
>>>Vlad
>>
>>In VFP help do a search on "Toolbar Object" (not "Toolbar Objects"). The following is from the Example from that topic.
>>PUBLIC tbrDesktop
>>tbrDesktop = CREATEOBJ('mytoolbar')
>>tbrDesktop.SHOW
>>
>>DEFINE CLASS myToolBar    AS Toolbar
>>	ADD OBJECT btnBold    AS CommandButton
>>	ADD OBJECT sep1	       AS Separator
>>	ADD OBJECT btnItalics AS CommandButton
>>	
>>	btnBold.HEIGHT = 20
>>	btnBold.WIDTH = 50
>>	btnBold.Caption = "Bold"
>>	btnItalics.HEIGHT = 20
>>	btnItalics.WIDTH = 50
>>	btnItalics.Caption = "Italic"
>>	btnItalics.FontBold = .F.
>>	
>>	LEFT	= 1
>>	TOP = 1
>>	WIDTH = 25
>>
>>	CAPTION = "Desktop Attributes"
>>	
>>
>>PROCEDURE Activate
>>	this.btnBold.FontBold = _SCREEN.FONTBOLD
>>	this.btnItalics.FontItalic = _SCREEN.FONTITALIC
>>	ENDPROC
>>	
>>	PROCEDURE btnBold.CLICK
>>	_SCREEN.FONTBOLD = !_SCREEN.FONTBOLD
>>	This.FontBold =_SCREEN.FONTBOLD
>>	ENDPROC
>>	
>>	PROCEDURE btnItalics.CLICK
>>	_SCREEN.FONTITALIC = !_SCREEN.FONTITALIC
>>	This.FontItalic = _SCREEN.FONTITALIC
>>	ENDPROC
>>ENDDEFINE
>>
>>I also found it on page 323 of the VFP 5 Developer's Guide. I was wondering where all the toolbar button names can be found. I will probably resort to some guess work like btnCut, btnCopy, btnPaste, etc.
>
>I don't understand why you're saying these are the buttons from VFP's toolbar. As far as I see, this is a toolbar to which you add two custom buttons. The sample shows also how you can manage these buttons, but I don't see the connection with VFP's buttons.
>
>Or maybe I am missing something?
>
>Vlad

You are correct. These are custom buttons. Guess it was just wishful thinking on my part. Is there no other way create a custom toolbar without the drag and drop way? I would like to do it code and place it in my custom class. I have yet to figure out how to put in a separator during the customization process.
Mark McCasland
Midlothian, TX USA
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform