Results 1 to 2 of 2

Thread: CreateObject

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Oct 2001
    Posts
    65

    CreateObject

    Hi,

    Could you please explain to me the following problem?

    I have two computers (one is a server and the other one is client). I created a server component and deloy it on MTS that reside in server comppiter. In client I have a application that use that component. Could you please tell me what's happen? when I use CreateObject statement. Where object is created in? (Server or Client). If in client I have a variable that is passed to a method of the object by reference. How to the object send the result to my variable? (the Automation will take care this, is it right?) How to object indetify my variable?...

    I saw in MSDN, The client tier can interactive with the Business Logic Tier by passing argurments ( there are 4 type of argurment are parameters, XML, Recordset, Array). If I use array do I care about lock or unlock the data in Multiple Users Enviroment? or The COM will take care that?

    Thanks in advance,

    Trung Luu

  2. #2
    Lively Member
    Join Date
    Aug 2002
    Posts
    126
    hi,
    generally objects running under MTS (or COM+) running in a surrogate process at the server.
    there is a possibility that an object will run at the client, it that case the object create in the client process.
    MTS uses DCOM to communicate the client with the server.
    when u pass an object as a paramter COM create proxy at the client (in this case the MTS server) and a stub at the side where the object reside (in this case the the client) and all the communication manages by COM - this is called marshaling.
    the object paramter must be installed on the MTS machine so MTS could create that object.
    when the object passes byval, COM marshaled the object only to the server.
    when u pass it byref it marshaled the object back to the client.
    so when ever declaring an object parameter use byval.

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