InfoConnect VBA Guide
Attachmate.Reflection.Objects.Emulation.IbmHosts Library / ThemeColor Object / SetBackgroundColor Method
An IbmTerminalAttributeOption Enumeration value that specifies the host color or attribute whose mapped color should be set.
The new background color mapping for the specified attribute.
Example
In This Topic
    SetBackgroundColor Method (ThemeColor)
    In This Topic
    Sets the current mapped background color for a given terminal attribute.
    Syntax
    expression.SetBackgroundColor( _
       ByVal attr As IbmTerminalAttributeOption, _
       ByVal newColor As Color _
    ) 
    where expression is a variable that represents a ThemeColor Object

    Parameters

    attr
    An IbmTerminalAttributeOption Enumeration value that specifies the host color or attribute whose mapped color should be set.
    newColor
    The new background color mapping for the specified attribute.
    Exceptions
    ExceptionDescription
    Throws an exception when the ThemeColor object is false.
    Example
    This sample changes the screen background color and saves the color in a new theme.
    Sub ChangeScreenBackgroundColor()
     
        'Declare and set a Themecolor object
        Dim Color As Attachmate_Reflection_Objects_Emulation_IbmHosts.ThemeColor
        Set Color = ThisIbmTerminal.Theme.ThemeColor
        
        'Change the background color
        Color.SetBackgroundColor IbmTerminalAttributeOption_ProtectedNormalAlpha, RGB(200, 100, 250)
        
        'Save the changes in a new theme to prevent InfoConnect from requesting to save new theme
        ThisIbmTerminal.Theme.SaveAs (Environ$("USERPROFILE") & "\Documents\Micro Focus\InfoConnect\Themes\myCustomTheme.themex")
        
        
    End Sub
    See Also