Contents Previous Next Subchapters

Easy Dialog Slider Fields
Syntax easydlg(captionbuttonsmessagelayout)
See Also slider

If a field type in the layout argument is "slider", the corresponding field setting contains the lower limit, current value, and upper limit for the field. Each of the values is separated by a comma. The field width must be greater than or equal to the maximum number of characters in the lower and upper limit, plus two.

     caption = "Slider_callback"
     buttons = {"Ok", "Cancel"}
     message = { ...
          "The time required is proportional to", ...
          "the maximum number of iterations." ...
     layout = "slider, max itr:, 20, 1, 5, 20"
     easydlg(caption, buttons, message, layout)
     function Slider_callback(button) begin
          print "button  =", button
          print "max itr: =", easydlg("max itr:")

If you paste the program above into the command line, the following dialog will be displayed:
If you change the slider value to 10, and then select the Ok button, the function Slider_callback will be called and it will print the text
     button  = Ok
     max itr = 10
in the Command window.