I'm trying to set the label and color of a command button based on what mode the system is in. the default of the button is bright yellow with no label. I have the following in On-Form-Entry:
// Changes the colors and functions of the GO Button depending on the mode
// Add Mode
IF @Mode() = 0
{
Label(GO_Button, "Get It!")
RGBColor(GO_Button, 0, 0, 0, 226, 145, 145) // Black text on Pinkish
}
ELSE
// Search Mode
IF @Mode() = 2
{
Label(GO_Button, "Get It!")
RGBColor(GO_Button, 0, 0, 0, 179, 255, 255) // Black text on light Blue
}
ELSE
// Update Mode
IF @Mode() = 1
{
Label(GO_Button, "New Search")
RGBColor(GO_Button, 0, 0, 0, 255, 255, 0) //Black text on bright Yellow
}
This works perfectly in Add mode. However, in Search and Update, all I see is the default button, no text on bright yellow. What am I missing?