gt; into an RGB long value.
''' &lt;/summary&gt;
''' &lt;param name="oClr"&gt;Colour to translate.&lt;/param&gt;
''' &lt;param name="hPal"&gt;Handle to colour palette to use when translating.&lt;/param&gt;
''' &lt;returns&gt;RGB equivalent, or -1 if none&lt;/returns&gt;
Public Function TranslateColor(ByVal oClr As OLE_COLOR, _
                        Optional hPal As Long = 0) As Long
    ' Convert Automation color to Windows color
    If OleTranslateColor(oClr, hPal, TranslateColor) Then
        TranslateC