Salesforce

WinHWND (Magic xpa 4.x)

« Go Back

Information

 
Created BySalesforce Service User
Approval Process StatusPublished
Objective
Description

WinHWND (Magic xpa 4.x)

Returns a window handle for a Magic xpa window. You can use this handle as a reference in a .NET library using the FromHandle() function.

Syntax:

WinHWND(generation)

Parameters:

generation – A number that represents the task's hierarchic position in the runtime task tree. 0 represents the current task, 1 its immediate ancestor, and so on.

Returns:

Value representing the Window's window handle, HWND.

Example:

WinHWND(1)

Note:

For SDI windows, WinHWND(0) returns the handle to the inner window created within the SDI Frame window and not the handle of the frame window itself.

If you want to get the handle of the frame window, you can get it as the return value of the following Magic xpa function:

CallDLL ('USER32.GetAncestor','444',WinHWND(0),2)

Exceptions:

This function is not supported in Web Client tasks.

Platform specific:

This function is not supported for mobile devices.

See also:

CtrlHWND

The Online and Rich Client Samples projects (program IF05 and RIF05)

Reference
Attachment 
Attachment