SetCoordinates (Method)
Â
Â
IWindow::SetCoordinates
Change the window size and/or position.
Â
Function SetCoordinates(Session As String, coords As WindowCoordinates) As Long
 Parameters
No | Name | Type | Optional | Default | Description |
---|---|---|---|---|---|
1 | Session | String | No | - | One character session ID |
2 | coord | No | - | Structure containing the new window coordinates | |
Return Code | Description | ||||
JGS_OK | The function was successful | ||||
JGS_PARAMETERERROR | Missing or invalid parameter | ||||
JGS_MEMORY | Insufficient memory | ||||
JGS_NOTCONNECTED | Your application is not currently connected to a valid session | ||||
JGS_PSENDED | The session was stopped | ||||
JGS_UNAVAILABLE | The session is in use by another application | ||||
JGS_SYSERROR | The function failed due to a system error |
Sample Code
Â
Dim mySession as String
Dim result as Long
Dim coords as WindowCoordinates
coords.x = 100
coords.y = 50
coords.cx = 500
coords.cy = 350
mySession = "E"
result = win.SetCoordinates(mySession, coords)
Dim result as Long
Dim coords as WindowCoordinates
coords.x = 100
coords.y = 50
coords.cx = 500
coords.cy = 350
mySession = "E"
result = win.SetCoordinates(mySession, coords)