// 2 button dialog example // To invert the most front image. // Modified from http://www.dmscripting.com/files/Example_Button_Enabling_Dialog.s // Renfong // 2021/03/24 // Global variables taggroup firstbutton, secondbutton number true=1 number false=0 image src // the class createbuttondialog is of the type user interface frame (UIFrame), and responds to interactions // with the dialog - in this case pressing buttons class CreateButtonDialog : uiframe { void button1response(object self) { //the response when the button is pressed self.SetElementIsEnabled("first", false); // these commands set the button as enabled or not enabled self.SetElementIsEnabled("second", true); // "second" in this command is the identifier of the button 'secondbutton' // put action1 here src.GetFrontImage() result(src.GetName()+" is picked.\n") }; void button2response(object self) { //the response when the second button is press...
Electron microscopy, Programming and Fun!!!