G Web Server Examples

VI Control CGI Parameters

name=vi_name
vi_name is the name of (or path to) a VI on which the CGI is going to operate. You can specify the name explicitly, i.e victrl.vi?name=example.vi or implicitly, i.e. victrl.vi?example.vi.

command=operation
This optional parameter specifies what operation (besides setting value(s)) should be performed on the specified VI. operation can be one of the following:

open

opens the front panel of the specified VI.
close
closes the front panel of the specified VI.
abort
aborts the execution of the specified VI.
run
loads the VI into memory and starts it running. If the VI's panel should be opened, also pass a parameter named open. The run command requires a path to the specified VI.

redirect=URL
URL specifies the document which the browser should display after the CGI has executed. If no redirect parameter is specified, the page in the browser does not change. If the redirect parameter specifies an empty URL, the browser is reqested to update that page from which the CGI was called.

SetBool,control_name
This parameter sets the value of the Boolean control control_name to the parameter's value. The value can be on, T or 1 for true and off, F or 0 for false.

SetBool,control_name,toggle
This parameter toggles the value of the Boolean control control_name.

SetString,control_name
This parameter sets the value of the String control control_name to the parameter's value.

SetInt,control_name
This parameter sets the value of the 32-bit integer control control_name to the parameter's value.

SetInt,control_name,inc
This parameter increments the value of the 32-bit integer control control_name by the parameter's value.

SetInt,control_name,dec
This parameter decrements the value of the 32-bit integer control control_name by the parameter's value.

SetFloat,control_name
This parameter sets the value of the double-precision floating point control control_name to the parameter's value.

SetFloat,control_name,inc
This parameter increments the value of the double-precision floating point control control_name by the parameter's value.

SetFloat,control_name,dec
This parameter decrements the value of the double-precision floating point control control_name by the parameter's value.


© National Instruments