Posted to microsoft.public.excel.programming
|
|
how to execute macro from vb 6.0 code?
Hi TOm,
Can u plse give me the sample code which will execute macro from vb
application?
Thanks,
Deepak
"Tom Ogilvy" wrote in message
...
these both worked for me from within Excel:
Sub Main()
Dim vArray As Variant
vArray = Range("A1:B10")
Application.Run "Macro1", vArray
End Sub
Sub tester()
Dim vArray As Variant
vArray = Range("A1:B10")
Macro1 vArray
End Sub
Sub Macro1(v As Variant)
Debug.Print LBound(v, 1), UBound(v, 1)
Debug.Print LBound(v, 2), UBound(v, 2)
Debug.Print v(UBound(v, 1), UBound(v, 2))
End Sub
I don't know whether you don't know about RUN or you are saying it doesn't
work with an array using automation.
--
Regards,
Tom Ogilvy
"B Deepak" wrote in message
...
Hi All,
I have a macro which will take string array as input and ll display it
into
the excel sheet. But I dont know how to call it frm vb application?
Please help me for the same.
Thanks n Regards,
Deepak
|