Creates a num box user control on the user window specified by
A num box is the same as text box user control, except it only allows the user to specify a number. A spinner is also available to change the value of the number.
The control is initially placed in the top-left corner of the user window, and must be placed by using the
-pos option, or by using the setControlPos command.
The command returns the Control ID of the user control, which should be saved for later operations on the control.
|int||yes||ID of user window to place the control on.|
|Name||Flag arguments||Argument type||Exclusive to||Comments|
|0||—||—||Specifies that the number should be evaluated as a floating point number.|
|0||—||—||Specifies that a spin control be attached to the control.|
|0||—||—||Specifies that the control should be hidden initially. Call showControl to subsequently make it visible. The default is for it to be visible.|
|1||float||—||Specifies the initial value of the control. Can be either a float or int.|
|1||integer array||—||A four-element int array representing a rectangle, which specifies the initial size/position of the control relative to the top left corner of the user window. The element order is Left, Top, Right, and Bottom. The default is a text box 20 units high by 50 units wide.|
|1||integer||—||Control ID of the form user control which will dynamically position this control.|
// Create a Check Box user control.
float $value = 5.25;
// First create a user window to place the Control on
$windowId = `createWindow "MyWindow"`;
// Create the Control on the Window, passing
// in the Window Id of the user window we
// just created. Make floating point, specifying the initial
// value and a spinner
$controlId = `createNumBox $windowId -num $value -spin -flt`;