getICanvas()

Returns the IDispatch interface for the Canvas of the module.

Synopsis

idispatch getICanvas(string moduleName);

Parameters

Parameter Meaning
moduleName The name of the module.

Return value

Idispatch interface

Error

Missing or wrong parameters

Description

The function returns the Idispatch interface. The interface is required for the attribute PanelPicture which is used to get a picture of a panel.

Example

The example below returns the canvas interface and gets a picture of a panel. The picture is also printed.

main()
{
  //get the canvas interface
  idispatch canvas = getICanvas(myModuleName());
  // get a picture of the Panel in the Canvas
  idispatch picture = canvas.PanelPicture;
  // print the picture
  OLEPicturePrint(picture, true);
}

Assignment

Availability

UI, CTRL