|
-
Feb 28th, 2002, 05:06 AM
#1
Thread Starter
Addicted Member
How to add icons to a Tool bar?
Hi everybody,
I add a toolbar control to my form using the microsoft windows common control. Now i am not able to add buttons or icons to the toolbar. Can anyone please tell me how to add the buttons to the tool bar.
Thanx.
Regards.
Samir
-
Feb 28th, 2002, 05:25 AM
#2
PowerPoster
You just dbl-click the toolbar or something to bring up it's special properties window.
To get pics on your buttons, you need to use an Image List Control, or something, I forget its name, and then you link the toolbar to that ImageList.
-----------------------------------------
-RJ
[email protected]
-----------------------------------------
-
Feb 28th, 2002, 05:30 AM
#3
Thread Starter
Addicted Member
Hi rjlohan
Thanx for ur reply.
Regards
Samir
-
Feb 28th, 2002, 05:32 AM
#4
PowerPoster
No worries.
-----------------------------------------
-RJ
[email protected]
-----------------------------------------
-
Feb 28th, 2002, 06:08 AM
#5
Fanatic Member
TOOLBAR ICONS
After you place the toolbar on your form:-
right click the toolbar and goto properties.
go to add buttons etc and use the imagelist 1 to assign icons etc.
Place an imagelist1 on your form and goto the properties and then add icons to the imagelist1 etc.
After you have place icons in your imagelist you goback to toolbar properties and reference the button to the icon you nrequire on that button.
HOPE THIS HELPS AND IS CLEAR ENOUGH
-
Feb 28th, 2002, 07:18 AM
#6
Thread Starter
Addicted Member
-
Feb 28th, 2002, 07:53 AM
#7
Fanatic Member
toolbar
No problem.
Hope i dident waffle too much
-
Feb 28th, 2002, 08:02 AM
#8
Fanatic Member
toolbar
I forgot to mention.
Once you have placed the buttons on the bar to use them when you run the program use some code like this.
Click on the toolbar and add some code like this:
Select case Button.index
case"1"
msgbox"You pressed the first button",vbinfomation
case"2"
msgbox"you hit number 2 button",vbcritical
end select
'Keep adding case statement for the number of buttons on your toolbar e.g I have 2 so there are 2 cases.
Ok
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|