-
I want to create a toolbar ( using the toolbar control in VB 6.0) and place two text boxes for user input on the toolbar. I also want to display caption for these text boxes. These two text boxes appear side by side between some toolbar buttons. Can anyone provide the code?
-
You can just add buttons with types vbPlaceholder. You can then put the TXBoxes on top. Is that your question or have I misunderstood?
-
thanks for the answer, but i think i didn't word my question correctly. I want to do the task at run time(which means through code). Also even though i set the ".Caption" property for the place holder button the Caption is not displayed.
-
If you want to do that...hold on, let me get VB on-line...
Code:
Private Sub Form_Load()
tb.Buttons.Add [Index], [Key], "See *", 4, 0
End Sub
You should add the KEY and possibly Index, depending on your case.
Now, as for captions...
You cannot add captions to a separator, right? The same goes for a placeholder, but there's a very simple way...use a label in place of it. Draw a label in front of the placeholder. & chr(0)
Got it?
-
Thanks,
I'd figured out as much as u have suggested but i was just hoping there's a better way of doing it!!
At least i know now that i was on the right track!