Multiple choices are available that the user can select, or a new value can be entered if the choices are not acceptable.


editchoice <name> [default "Default value"] [display <display hint>] { <choices> }


  • choices - required the available items that can be selected. This can be a list of strings or a TCL expression
  • default - the value presented as the default value if no value had previously been selected before. This can be a string or a TCL expression.
  • display - gives a hint to the renderer about how this element should be displayed. This can be “small”, “medium”, “large”, “xlarge”, or “xxlarge”


section example4 {
  editchoice poolselect tcl {
    set objs [tmsh::get_config /ltm pool]
    foreach obj $objs {
      append results [tmsh::get_name $obj]
      append results "\n"
    return $results
text {
  example4 "Pool Selection"
  example4.poolselect "Please select one or more pools, or enter a new pool name. "

Resulting UI presentation:

Codeshare Entries

The BIG-IP API Reference documentation contains community-contributed content. F5 does not monitor or control community code contributions. We make no guarantees or warranties regarding the available code, and it may contain errors, defects, bugs, inaccuracies, or security vulnerabilities. Your access to and use of any code available in the BIG-IP API reference guides is solely at your own risk.