IBM Support

IBM Personal Communications ActiveX controls

Troubleshooting


Problem

This document explains how ActiveX controls can be set up in IBM Personal Communications

Symptom


Introduction

The Support of ActiveX/OLE in IBM Personal Communications (PCOMM) is limited and has minimal support for Office/Lotus tools, which can be used further in automating the operations within PCOMM. However, PCOMM does not provide a way to embed itself as a full-fledged ActiveX object or have it instantiated as a Form Object.

While PCOMM provides the API interface (HACL Automation / COM objects) for .NET Framework targeted applications (such as the WinForms application), the ActiveX/OLE support provided by PCOMM is primitive. There is no API interface to embed PCOMM Runtime.

What has changed with IBM Personal Communications v13.0.1.0?

PCOMM 13.0.1.0 packages pcsctrX.ocx – an ActiveX Control it can be hosted in an OLE container. An OLE container control lets you add OLE objects to your applications. OLE objects include ActiveX Controls (.OCX files) and insert-able OLE objects created in other applications such as Microsoft Word and Microsoft Excel.

After adding pcsctrX.ocx into an OLE container or an Automation Client, users can start a PCOMM session in the ActiveX control by providing Session ID (optional) and the PCOMM Workstation profile (mandatory). Once started, the PCOMM session will be embedded in the application.

This control supports:
ActiveX Control for PCOMM achieves all the features of Statically and Dynamically Embedding PCOMM as an ActiveX control object in a windows Form (or .NET application).
Users can launch PCOMM by providing two important parameters:
1. Session ID (Optional):
  • When set: This can be set from ‘A’ to ‘Z’.
  • Blank: The Control logic generates the SessionID and Launches the PCOMM with the next available Session ID.
  • Already existing/launched: Provides an option to the user to embed the same session in the ActiveX control. 
2. Session Profile (mandatory): The user must provide a valid .ws profile name, or else the launch of Embedded PCOMM will fail.
  • Session Profile name may or may not have a ‘.ws’ extension.
  • If the path is not provided, then the default path is picked up from the registry.
  • With a Customized path, PCOMM is launched with the .ws file from the customized path.
  • Automation/Screen Scraping: Operations based on automation objects (HACL) and Emulator Programming (ELLAHPI) are supported.
  • Menu and Toolbar Items in the Embedded PCOMM (pcsctrX) are hidden.
  • Errors/Exceptions are handled.

What has changed with IBM Personal Communications v15.0.0.0?
  1. The ActiveX component is supported in PCOMM 64-bit.
  2. ActiveX component pcsctrX.ocx automatically registered at the time of PCOMM installation.
System Requirements
For version 13 and version 14:

1. Visual Studio 2005 or higher: To build a client application using pcsctrX.ocx.

2. Microsoft Office (32-bit ): If the client application executes on a Microsoft Office application.

3. IBM Personal Communication Ver 13.0.1.0 or higher.

4. ActiveX component pcsctrX.ocx must be registered.

NoteActiveX controls is supported only in 32-bit for PCOMM 13 and 14 versions.

Steps to Register

Register pcsctrX.ocx on a system where users need to execute the OLE/Automation Container Application built with pcsctrX.ocx.

  • To register, execute the below command in the command window with elevated permission: regsvr32 pcsctrX.ocx
  • To unregister, execute the below command in the command window with elevated permission: regsvr32 /u pcsctrX.ocx

For version 15

1. Visual Studio 2005 or higher: To build a client application using pcsctrX.ocx.

2. Microsoft Office: a 32-bit or 64-bit office version is required based on the PCOMM 64-bit and 32-bit versions installed in the system. If the client application executes on a Microsoft Office application.

3. IBM Personal Communication version 15.0.0.0 or higher.

Note: ActiveX component pcsctrX.ocx automatically registered at the time of PCOMM installation.

Interface

CHAR pcsOcxStartSession (CHAR sessID, BSTR wsProfile)
Starts PCOMM session in the ActiveX Control window by using a specified workstation profile and A (optional) short session ID can also be specified.

Arguments

  1. • sessID: Presentation space short session ID. It is optional and if not provided then the next available session ID is assigned.
  2. • wsProfile: Path and complete filename of the profile to load. The path is optional but a complete filename is mandatory.
  3. • Return Value
  • Returns the Presentation space short session ID.
  • If sessID was provided, then the same value is returned else the newly assigned session Id is returned.
  • If the PCOMM session failed to start, then a blank/NULL value is returned.

VARIANT_BOOL pcsOcxConnectSession(void)
Connect the PCOMM emulator to the host data stream. This has the same effect as going to the PCOMM emulator Communication menu and choosing Connect.

Arguments
  • Return Value
  • Returns true if connected successfully else false.

VARIANT_BOOL pcsOcxDisconnectSession(void)
Disconnect the PCOMM emulator from the host data stream. This has the same effect as going to the PCOMM emulator Communication menu and choosing Disconnect.

Arguments
  • Return Value
  • Returns true if disconnected successfully else false.

Limitations
ActiveX controls support only English Language.

PCOMM Window Recognition
pcsctrX.ocx recognizes the PCOMM window based on its name, “Session ID *“.
for e.g. Session A – [24 x 80].
If this naming standard is not followed (by changing Edit->Preferences->Display Setup configurations), then the PCOMM session will be failed to appear in the ActiveX control screen.

Redundant Disconnect context item
Disconnect context Menu item which appears in a static invoke a method on the pcsctrX ActiveX control is redundant. This limitation would be taken care in the upcoming release.

Menu and Toolbar state conflict
If the PCOMM Session profile is the same as the one specified in the Embedded ActiveX control, then PCOMM shall be Embedded in the ActiveX control without any change in state, however, the Menu and the Toolbar items are visible. This limitation would be taken care of in the upcoming release.

Known Issues
To receive notification of all OIA events in a pcsctrX.ocx container application used the IBM PCOMM method ‘RegisterOIAEvent‘, but the container application fails to receive event notification from autOIA.

Observation
It is a defect in the automation API ‘RegisterOIAEvent’.

[{"Type":"MASTER","Line of Business":{"code":"LOB70","label":"Z TPS"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SSEQ5Y","label":"Personal Communications"},"ARM Category":[{"code":"a8m0z0000000CBWAA2","label":"PCOMM"}],"ARM Case Number":"","Platform":[{"code":"PF033","label":"Windows"}],"Version":"12.0.3;13.0.0;15.0.0"}]

Log InLog in to view more of this document

This document has the abstract of a technical article that is available to authorized users once you have logged on. Please use Log in button above to access the full document. After log in, if you do not have the right authorization for this document, there will be instructions on what to do next.

Document Information

Modified date:
15 December 2022

UID

swg22014525