ad_db_select_widget

EveAndersson.com : API Browser : ad_db_select_widget

ad_db_select_widget

ad_db_select_widget [ -size size ] [ -multiple multiple ] \
    [ -default default ] [ -option_list option_list ] \
    [ -blank_if_no_db blank_if_no_db ] \
    [ -hidden_if_one_db hidden_if_one_db ] [ -bind bind ] \
    statement_name sql_qry name
Defined in packages/acs-core/widgets-procs.tcl

given a sql query this generates a select group. If there is only one value it returns the text and a hidden variable setting that value. The first selected column should contain the optionlist items. The second selected column should contain the optionlist values.

option_list is a list in the same format (i.e. {{str val} {str2 val2}...}) which is prepended to the list

if sql_qry is null then the list is constructed from option_list only.

if there is only one item the select is not generated and the value is passed in hidden form variable.

if -multiple is given the a multi select is returned.

if -blank_if_no_db set then do not return a select widget unless there are rows from the database

Switches:
-size (defaults to "0")
-multiple (defaults to "0")
-default (optional)
-option_list (optional)
-blank_if_no_db (defaults to "0")
-hidden_if_one_db (defaults to "0")
-bind (optional)

Parameters:
statement_name
sql_qry
name
[ show source ]

Show another procedure:

eve@eveandersson.com