| SFColor |  |  |
SFColor Object
See also: Using field value objects.
| |

 |
Red property, read/write, Single.
Gets or sets a Red component of the SFColor or MFColor field value.
The following example shifts a SFColor value.
Dim f As Field
Set f = Document.RootNodes.Add("Fog")("color")
f.Red = f.Red / 2
f.Green = f.Green / 2
f.Blue = f.Blue / 2
|
|

| |

 |
Green property, read/write, Single.
Gets or sets a Green component of the SFColor or MFColor field value.
|

| |

 |
Blue property, read/write, Single.
Gets or sets a Blue component of the SFColor or MFColor field value.
|

| |

 |
Set method, ( Red As Single, Green As Single, Blue As Single ).
Sets a Red, Green and Blue components of the SFColor or MFColor field value.
The following example sets a SFColor value by three different ways.
Dim f As Field
Set f = ...
'First method (slowest, but preserves formatting):
f.Red = 0.2
f.Green = 1
f.Blue = 0.4
'Second method (fast and basically preserves formatting):
f.Set 0.2, 1, 0.4
'Third method (fastest, but cancels formatting):
f = Array(0.2, 1, 0.4)
|
|

|
|
|