====== jLamp ====== The [[https://api.comfiletech.com/csharp/api/ComfileTech.jControls.jLamp.html|jLamp]] control is designed to mimic an indicator lamp typically found on dash boards and control panels. Like most controls in the jControls library, it has a rich appearance, employing jControls' [[jcontrols:fills_and_borders:index|fill, border]], [[jcontrols:shape_and_cornerradii:index|shape, corner radii]], [[jcontrols:gloss_and_dropshadow:index#dropshadow_property|drop shadow]], and [[jcontrols:text_features:index|text features]], along with a few additional features. ===== OnAppearance and OffAppearance Properties ===== The [[https://api.comfiletech.com/csharp/api/ComfileTech.jControls.jOnOffControl-1.OnAppearance.html#ComfileTech_jControls_jOnOffControl_1_OnAppearance|OnAppearance]] property describes the appearance of the lamp when it is on, and the [[https://api.comfiletech.com/csharp/api/ComfileTech.jControls.jOnOffControl-1.OffAppearance.html|OffAppearance]] property describes the appearance of the lamp when it is off. | {{ https://downloads.comfiletech.com/jControls/videos/jlamp_appearance.mp4?172x164 }} | {{ jlamp_appearance_properties.png }} | ===== IsOn Property ===== This [[https://api.comfiletech.com/csharp/api/ComfileTech.jControls.jOnOffControl-1.IsOn.html|IsOn]] property can be set at design time or runtime to cause the lamp to turn on or off. It can be read at runtime to inspect whether or not the lamp is on or off. The ''IsOn'' property returns ''true'' when the lamp is on, and ''false'' when the lamp is off. Use this property at design time to style the jLamp's on and off appearances without having to run the program to verify. {{ https://downloads.comfiletech.com/jControls/videos/jlamp_ison.mp4?368x96 }} ===== IsOnChanged Event ===== The [[https://api.comfiletech.com/csharp/api/ComfileTech.jControls.jOnOffControl-1.IsOnChanged.html|IsOnChanged]] event is fired any time the ''IsOn'' property is changed. It can be used at runtime to notify another part of the program any time the lamp is turned on or off.