Table of Contents

ControlAddIn WebPageViewer

Namespace: System.Integration

Methods

InitializeIFrame

Function that initializes iframe Call this before SetContent or Navigate.

procedure InitializeIFrame(Ratio: Text)

Parameters

Name Type Description
Ratio Text

The ratio of width to height of iframe. For example "16:9".

InitializeFullIFrame

Function that initializes iframe, ignoring ratio values Call this before SetContent or Navigate.

procedure InitializeFullIFrame()

SetContent

Function that sets the content html

procedure SetContent(Html: Text)

Parameters

Name Type Description
Html Text

The html content to display.

SetContent

Function that sets the content html and executes some JavaScript

procedure SetContent(Html: Text, JavaScript: Text)

Parameters

Name Type Description
Html Text

The html content to display.

JavaScript Text

The html content to display.

Navigate

Function that sets the content url

procedure Navigate(Url: Text)

Parameters

Name Type Description
Url Text

Url to display.

Navigate

Function that sets the content url with parameter data

procedure Navigate(Url: Text, Method: Text, Data: Text)

Parameters

Name Type Description
Url Text

Url to display.

Method Text

HTTP method to use.

Data Text

Data to send (JSON encoded string).

PostMessage

Function to post a message to parent window.

procedure PostMessage(Message: Text, TargetOrigin: Text, ConvertToJson: Boolean)

Parameters

Name Type Description
Message Text

Data to be sent to the other window

TargetOrigin Text

Specifies what the origin of otherWindow must be for the event to be dispatched, either as the literal string "*" (indicating no preference) or as a URI.

ConvertToJson Boolean

Flag indicating whether we must convert message to Json or not.

LinksOpenInNewWindow

Function to force hyperlinks to open in a new page

procedure LinksOpenInNewWindow()

InvokeEvent

Function to trigger a WebPageViewerEvent with custom data

procedure InvokeEvent(Data: Text)

Parameters

Name Type Description
Data Text

The data to pass in the event.

SubscribeToEvent

Function to subscribe to window events and trigger a WebPageViewerEvent with the data provided by the event

procedure SubscribeToEvent(EventName: Text, Origin: Text)

Parameters

Name Type Description
EventName Text

The name of window event

Origin Text

Filters event by origin of the publisher

SetCallbacksFromSubscribedEventToIgnore

Function to ignore callbacks occuring due to subscribed events. This will improve performance by telling client not to send messages back to server if not required.

procedure SetCallbacksFromSubscribedEventToIgnore(EventName: Text, CallbackResults: JsonArray)

Parameters

Name Type Description
EventName Text
CallbackResults JsonArray

Remarks

Send empty callbackResults to undo previous entry.

See also