![]() |
OnImages()








Public Function |
Declared in: NiButton.h |
Declaration
CNiImage OnImages( long imageIndex);
Description
Gets the image object corresponding to the On state of the CNiButton control that is associated with the specified part of the CNiButton control.
Notes:
1. You can use the OnImages function to perform operations like loading custom bitmaps and adjusting blink or animation speeds for the button control in the On state. For example,
CNiButton1.OnImages(1).BlinkInterval = CNiImage::SpeedFast;
causes the button caption to blink quickly when the control is in the On state. The caption's BlinkInterval property remains unchanged in the Off state.
2. Use the OffImages function to control images in the Off state.
Parameters
long imageIndex
Specifies the index of the image object to return. The list below includes valid image indices.
- CNiButton::1 - caption
- CNiButton::2 - background
- CNiButton::3 - on Text
- CNiButton::4 - off Text
- CNiButton::5 - image