In this month's
Inside Sesame there is a short article about a trick to notify users that the command button they've clicked on is actually doing something. The article details how to change the button's label from its default of black to red, using the following code:
RGBColor(ThisElement, 232, 0, 50, -1, -1, -1)
ForceRedraw()
Loiter(500)
RGBColor(ThisElement, 0, 0, 0, -1, -1, -1)
ForceRedraw()
This works just fine, but I would like to do something different. I would like to keep the label text black but change the background color from its default of yellow to light green. I tried the following code:
RGBColor(ThisElement, -1, -1, -1, 150, 255, 150)
ForceRedraw()
Loiter(500)
RGBColor(ThisElement, -1, -1, -1, 255, 255, 0)
ForceRedraw()
But this is not working. The button just changes to a light gray, which is does anyway when clicked. Am I missing something?
Help is appreciated, as always.