J
JonWayne
Can the OnAction property of a commandbarbutton be set to call a function
with arguments? If so, how is it formatted?
with arguments? If so, how is it formatted?
Can the OnAction property of a commandbarbutton be set to call a function
with arguments? If so, how is it formatted?
JonWayne said:I was hoping for an example. I have the function written, which accepts 2
String arguments. Its the OnAction setting is what I am unsure about, which
is a string - and in this case, passing 2 strings to a calling function. How
do I write it? OnAction = "SomeFunc(""StrArg1"",""StrArg2"")". Would that be
an example of how its is quoted?
I was hoping for an example. I have the function written, which accepts 2
String arguments. Its the OnAction setting is what I am unsure about, which
is a string - and in this case, passing 2 strings to a calling function. How
do I write it? OnAction = "SomeFunc(""StrArg1"",""StrArg2"")". Would that be
an example of how its is quoted?
Thanks
John Nurick said:Public Sub CallMyFunction()
Dim RetVal As Variant
RetVal = MyFunction(Argument1, Argument2)
End Sub
JonWayne said:Somehow, I must not be explaining myself properly here. If you had to set
the OnAction property to call a function which takes 2 string args, how
would you enter that setting? Note, the function is already written, I
dont need to know how to write a function. What I need to know is how to set
the OnAction property to call the function, passing the 2 arguments.