Results 1 to 4 of 4

Thread: Global Object used by diff. applications

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2006
    Posts
    2

    Global Object used by diff. applications

    Hello!

    I'm relatively new to visual basic 6 (coming from the Java World) and have a question: is it possible to create a kind of global object (which stays in the memory) wich can be used by more than one application at the same time? A kind of VB-Enterprise Java Bean?

    The problem is: i have application a, b and c. Application A adds things to lets say an array. Application B also adds stuff to the same array. Application C takes all the stored things of this array and processes the data somehow (e.g. stores the complete array into a database).

    Can this be done with vb6 (I'm quite sure it can be done) and if, how?

    Thank you in advance, I appreciate any help!!

    Regards,
    max

  2. #2
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Re: Global Object used by diff. applications

    If all of these applications are running on the same machine then you can create an ActiveX EXE and use GetObject() to retain a reference to an existing object of this application.

  3. #3

    Thread Starter
    New Member
    Join Date
    Jan 2006
    Posts
    2

    Re: Global Object used by diff. applications

    Thank you very much! I ran across an "out-of-process-server" couple of minutes ago and I think it's the same concept you mentioned. But the book I have says that passing parameters to an activeX .exe takes is time-intensive. That's a problem due to my applications are very time-critical. Can you think of any faster way?

    But thank you anyway!

  4. #4
    PowerPoster Dave Sell's Avatar
    Join Date
    Mar 2004
    Location
    /dev/null
    Posts
    2,961

    Re: Global Object used by diff. applications

    You can use an ActiveX EXE to do this and it won't be as slow as you think. Search my name and Singleton for some nice examples.

    P.S. Any solution you use will be out-of process by the very definition of what you are asking for.
    Nobody knows what software they want until after you've delivered what they originally asked for.

    Don't solve problems which don't exist.

    "If I had eight hours to cut down a tree, I'd spend six hours sharpening my axe." --- Abraham Lincoln (1809-1865)

    2 idiots don't make a genius.

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