|
|
|
Page 1 of 1 |
[ 4 posts ] |
|
 Runtime error 91 when trying to play a macro in VB : Developer's Corner
|
|
Posted: October 5th, 2003, 10:32 pm
|
|
|
|
Sulfuric
Sulfuric's Reps:
|
I'm trying to add the macro commands to my plugin that i'm making, the XUMacroHelperLib
I've got that referenced and then I put in
Public MacroHelper As XUMacroHelperLib.MacroWindow
then I try to play a macro on button press as
Private Sub m_btn_Button_Accepted(ByVal nID As Long)
MacroHelper.SetPlayOnce
MacroHelper.Play ("MacroTest")
End Sub
But I get a runtime error 91 when I press the button. is there an initialization code line i'm missing? Why doesnt it play?
|
|
|
|
|
Posted: October 6th, 2003, 5:45 am
|
|
|
|
Admin
Admin's Reps:
|
See the documentation in the scripting plugins forum. You need to actually create the macro object not just reference it. Ie, use CreateObject.
|
|
|
|
|
Posted: October 6th, 2003, 12:48 pm
|
|
|
|
Sulfuric
Sulfuric's Reps:
|
Is that the same in VB6? I'm using VB6 not the scripts. I have a window made and all the buttons, but im trying to play the macro with the XUMacroHelpLib. Do I need to use XUScriptHelper too?
when I tried to use CreateObject it gave like error 424 object required.
|
|
|
|
|
Posted: October 6th, 2003, 6:43 pm
|
|
|
|
Admin
Admin's Reps:
|
No, you just use the
Dim variable
Set varable = CreateObject("XUMacroHelpLib.MacroWindow")
|
|
|
|
|
Who is online |
|
Users browsing this forum: No registered users and 5 guests |
|
|
|