Using a PowerBuilder COM server with a COM-enabled application

StepsTo use a PowerBuilder COM server with a COM-enabled application:

  1. Deploy the PowerBuilder COM server to the user’s computer.

  2. Deploy the PowerBuilder virtual machine (PBVM105.DLL) and any other required modules (such as PBCOMRT105.DLL, PBDWE105.DLL, or any required database software) to the computer containing the PowerBuilder COM server.

  3. Register the PowerBuilder COM server on the user’s computer.

  4. Write a client application that calls PB object functions in the PowerBuilder COM server.

    See “Accessing PowerBuilder COM servers from clients”.

Registering PowerBuilder COM servers When you deploy a PowerBuilder COM server, you need to add information to the registry to enable COM to create instances of the server’s objects. PowerBuilder COM servers are self-registering—you do not need to create a separate registration file. To register a PowerBuilder COM server, use the REGSVR32 utility. For example:

regsvr32.exe path_to_server\mycomserver.dll

If you want to access the server from a remote client, you need to make an additional change to the registry and you may need to configure the client for remote access to the server. For more information, see “Using PowerBuilder COM servers and objects with DCOM”.

NoteRegistering automatically for testing For testing purposes, you can check the box on the General property page that registers the server on the development computer automatically when it has been generated. To avoid making unnecessary registry entries on your computer, check this box only when you are ready to test the PowerBuilder COM server.