CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Sep 1999
    Location
    Bangalore, India
    Posts
    21

    How to pass arguments to ActiveX Exe

    Hi,
    I have a main program which uses an ActiveX exe. I need to pass some arguments to this ActiveX exe. How can I pass argument as command line to this AX from main program? (And the Class Initialise of the class inside event Active X does not take parametres).
    Does any one know how to tackle this?
    Thank you
    Arjun

    Software Engineer
    Bangalore

  2. #2
    Join Date
    May 1999
    Posts
    3,332

    Re: How to pass arguments to ActiveX Exe

    add a public property to a public class of your activex exe and set that, or
    run it via Shell command and pass parameters to the ActiveX Exe (access those command line parameters via Command$ variable)


  3. #3
    Join Date
    Sep 1999
    Location
    Bangalore, India
    Posts
    21

    Re: How to pass arguments to ActiveX Exe

    Hi,
    The requirement is that the AX class initialization should establish a connection and the parametres to do this should be available at the class initialization time. So the public Let Interface cannot be used. If I try the Shell to invoke with these parametres as command line, I am getting "-Embedding" when I use the Command() function.
    Is there any method to solve this?
    Thanks in advance
    Arjun


    Software Engineer
    Bangalore

  4. #4
    Join Date
    May 1999
    Posts
    3,332

    Re: How to pass arguments to ActiveX Exe

    VB does NOT have constructors (Class-Init...) that allow you to pass parameters.
    This could change in VB 7 (I have seen a demo).

    INHO, the only way is:
    instantiate the class
    intialize properties
    call a method



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured