|
-
Jan 2nd, 2000, 05:57 PM
#1
Thread Starter
Lively Member
Is it possible that I can have a menu that I can change captions from executing time? Ie, when someone clicks on one item, the menu relates to that without having to have tons of different menus?
Thanks
-
Jan 2nd, 2000, 10:36 PM
#2
Junior Member
You must reference your Project to the MS Office 8.0 Object Library then you can use this objects to add or remove menus to your command bar.
E.g:
Code:
Dim newCmdButton as CommandBarButton
Set newCmdButton = CommandBars(2).Controls.Add(1, , , VBInstance.CommandBars(2).Controls.Count)
With newCmdButton
.Caption = "MyCaption"
End With
Regards,
Frank
-
Jan 2nd, 2000, 10:39 PM
#3
Junior Member
Damn!!!
Why are there no linebreaks in the codesection! HELP!!!
Code:
Here is the first line
And where is the empty line??
sldfkj
-
Jan 3rd, 2000, 01:26 AM
#4
Guru
Code:
First Line
Skip 2 lines
Skip 1 line
-
Jan 3rd, 2000, 01:27 AM
#5
Guru
looks like you have to skip 2 lines instead of just 1.....
-
Jan 3rd, 2000, 01:32 AM
#6
I may not understand your original question, but you can change a manu's caption anytime in your code with someting like MyMenu.Caption = "this is a new caption"
------------------
Marty
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
|