Kinook Software Forum

Go Back   Kinook Software Forum > Visual Build Professional > [VBP] General Discussion

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 04-21-2011, 12:00 AM
aaronlawrence aaronlawrence is online now
Registered User
 
Join Date: 04-11-2011
Posts: 6
Trouble accessing macros from script

I want to create some temporary macros and then update them from script. I can't get this to work.

vbld_TempMacros().Add("SUCCEEDED_STEPS")

...

vbld_TempMacro("SUCCEEDED_STEPS") = vbld_TempMacro("SUCCEEDED_STEPS") + 1

I also tried adding via Application.Macros( vbldTemporaryMacros )...

The only way I have been able to update macros from script was when I did it with Project macros that were created in the IDE. But this results in the project itself becoming modified.
Reply With Quote
  #2  
Old 04-21-2011, 06:37 AM
kinook kinook is online now
Administrator
 
Join Date: 03-06-2001
Location: Colorado
Posts: 6,034
A macro is an object, so you need to update its Value property, not the object itself.
http://www.kinook.com/VisBuildPro/Ma...acroobject.htm

Code:
Set objMacro = vbld_TempMacros().Add("SUCCEEDED_STEPS", 0)

objMacro.Value = objMacro.Value + 1
Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



All times are GMT -5. The time now is 10:57 AM.


Copyright © 1999-2023 Kinook Software, Inc.