Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Command Bars
  New Posts New Posts RSS Feed - Urgent Help - Ribbon
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Urgent Help - Ribbon

 Post Reply Post Reply
Author
Message
AMSH View Drop Down
Groupie
Groupie
Avatar

Joined: 27 June 2007
Location: Yemen
Status: Offline
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote AMSH Quote  Post ReplyReply Direct Link To This Post Topic: Urgent Help - Ribbon
    Posted: 22 November 2009 at 7:50am
Please Help...
I want to create a tag value for all RibbonBar buttons

Dim Action As CommandBarAction
Set Action = CommandBars.Actions(ID_FORM_CLOSE)
Action.Tag = 999

But this message appears when I run the program at that's code "Object variable or with block variable not set"

VB6
v 13.2.1
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 23 November 2009 at 4:59am
Hi,
 
So are you sure you call it after ID_FORM_CLOSE Action was created ?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
AMSH View Drop Down
Groupie
Groupie
Avatar

Joined: 27 June 2007
Location: Yemen
Status: Offline
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote AMSH Quote  Post ReplyReply Direct Link To This Post Posted: 23 November 2009 at 6:03am
yes
Back to Top
SuperMario View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 February 2004
Status: Offline
Points: 18057
Post Options Post Options   Thanks (0) Thanks(0)   Quote SuperMario Quote  Post ReplyReply Direct Link To This Post Posted: 25 November 2009 at 9:14am
Modify a sample to use your code and attache it here please.
Back to Top
AMSH View Drop Down
Groupie
Groupie
Avatar

Joined: 27 June 2007
Location: Yemen
Status: Offline
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote AMSH Quote  Post ReplyReply Direct Link To This Post Posted: 06 December 2009 at 4:37am
Originally posted by AMSH AMSH wrote:

Please Help...
I want to create a tag value for all RibbonBar buttons

Dim Action As CommandBarAction
Set Action = CommandBars.Actions(ID_FORM_CLOSE)
Action.Tag = 999

But this message appears when I run the program at that's code "Object variable or with block variable not set"

VB6
v 13.2.1



Here you are.
20091206_043208_Emp.rar
Back to Top
AMSH View Drop Down
Groupie
Groupie
Avatar

Joined: 27 June 2007
Location: Yemen
Status: Offline
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote AMSH Quote  Post ReplyReply Direct Link To This Post Posted: 07 December 2009 at 7:31am
Hello...........
Back to Top
shipwreck View Drop Down
Senior Member
Senior Member
Avatar

Joined: 18 April 2008
Location: United States
Status: Offline
Points: 308
Post Options Post Options   Thanks (0) Thanks(0)   Quote shipwreck Quote  Post ReplyReply Direct Link To This Post Posted: 10 December 2009 at 6:55am
Try referencing the control a different way AMSH.
Example:
Dim Action As CommandBarAction
Set Action = CommandBars.Actions(ID_FORM_CLOSE)
commandbars.findcontrol ("Control Type", ID_FORM_CLOSE).tag = 999
Product: Xtreme Suite Pro (Active-X), Version 15.3.1

Platform: Windows 7 Ultimate SP1 (64Bit) & Windows XP Mode SP3 (32Bit)

Language: Visual Basic 6.0 SP6
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 11 December 2009 at 2:04am
Hi,
 
You need to enable Actions.
 
Call CommandBars.EnableActions before you create any control.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
AMSH View Drop Down
Groupie
Groupie
Avatar

Joined: 27 June 2007
Location: Yemen
Status: Offline
Points: 20
Post Options Post Options   Thanks (0) Thanks(0)   Quote AMSH Quote  Post ReplyReply Direct Link To This Post Posted: 15 February 2010 at 6:39am
Originally posted by shipwreck shipwreck wrote:

Try referencing the control a different way AMSH.
Example:
Dim Action As CommandBarAction
Set Action = CommandBars.Actions(ID_FORM_CLOSE)
commandbars.findcontrol ("Control Type", ID_FORM_CLOSE).tag = 999


I did that brother, but not working
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 15 February 2010 at 10:09am
Hi,
 
You have to call CommandBars.EnableActions BEFORE !!! you create any control. That is what Oleg said and I looked into your project and I don't see CommandBars.EnableActions at all.
 
Just add CommandBars.EnableActions somewhere before adding controls to Commandbars and it will work
 
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.188 seconds.