docs

Home All functions Legacy functions Categories

vuShellOpenUrl()

vuShellOpenUrl(*CSTRING Url,*CSTRING OutText,LONG OutTextLen),SIGNED,PROC,PASCAL,RAW,NAME('vuShellOpenUrl')

Purpose

Attempts to launch a URL in the user’s default browser and writes diagnostic text to an output buffer.

Parameters

| Parameter | Type | Description | |—|—|—| | Url | *CSTRING | URL to open. | | OutText | *CSTRING | Output buffer for success/failure diagnostics. | | OutTextLen | LONG | Size of xOutText in bytes. |

Return value / error codes

Example (Clarion)

MAP
  MODULE('vuMail.dll')
    vuShellOpenUrl(*CSTRING Url,*CSTRING OutText,LONG OutTextLen),SIGNED,PROC,PASCAL,RAW,NAME('vuShellOpenUrl')
  END
END

rc      LONG
url     CSTRING(512)
outTxt  CSTRING(512)

url = 'https://login.microsoftonline.com/'
outTxt = ''
rc = vuShellOpenUrl(url, outTxt, SIZE(outTxt))

IF rc = 1
  MESSAGE('Browser launch requested. ' & outTxt)
ELSE
  MESSAGE('Launch failed. rc=' & rc & ' msg=' & outTxt)
END

Notes

Home All functions Legacy functions Categories