Previous Document Next Document

Object Model Reference : Classes : C : CorelScriptTools : Methods : CorelScriptTools.GetColor


CorelScriptTools.GetColor

Function GetColor(Red As Long, Green As Long, Blue As Long) As Boolean

Description

Member of CorelScriptTools

The GetColor method displays a standard Windows Color dialog box and returns color setting values from the RGB color model (Red, Green, Blue).

Parameter
Definition
Red
Specifies the numeric variable that is passed the Red setting of the selected color (0 to 255). You can also use this variable to set an initial value.
Green
Specifies the numeric variable that is passed the Green setting of the selected color (0 to 255). You can also use this variable to set an initial value.
Blue
Specifies the numeric variable that is passed the Blue setting of the selected color (0 to 255). You can also use this variable to set an initial value.

The GetColor function returns one of the following values:

 
True (-1) = the Cancel button was not clicked
 
False (0) = the Cancel button was clicked
Example

Here is a code example:

GETCOLOR MyRed%, MyGreen%, MyBlue%

The above example displays the following dialog box and returns the RGB color settings for the selected color to the numeric variables MyRed, MyGreen, and MyBlue.

Previous Document Next Document Back to Top

Copyright 2013 Corel Corporation. All rights reserved.