DBWList

<< Click to Display Table of Contents >>

Navigation:  Programming Mechworks PDM > DBWCommandShell > Library Reference > UserInterface >

DBWList

Description

Shows a dialog box that allows to choose between customized entries.

Syntax

 Function DBWList(Values, Title, DefaultValue, ByRef Resp)

Parameters

Values

string that contains options to visualize.

It must be of the form: "value1" & vbCRLF & "value2" & vbCRLF & ...

DefaultValue

integer (starting from 0) that represents the value to highlight at start.
If the passed value is out of range no entry is highlighted.

Title

dialog box title

DBWList

Return Values

TRUE

if the user has closed the dialog by pressing the OK button

FALSE

if the user has closed the dialog by pressing the CANCEL button

Resp

Contains the item selected. If the function has a FALSE value resp contains a null string.

See also

Function DBWListFiles
Function DBWListFromFile
Function DBWListFromQuery

Example

values = "value1" & vbCRLF & "value2" & vbCRLF & "value3" & vbCRLF & "value4" & vbCRLF
title = "Item selection"
default_value = 1
ok = DBWList(values, title, default_value, resp)
if ok then
 msgbox "The value selected is " & vbCRLF & resp
else
 msgbox "The user has canceled"
end if