FormListDeleteText
Deletes an existing text entry from a combo box or a list box while the form is displayed. It only deletes the text from the list - it does not change the selection. Call this function only when the form is displayed, for example, from a field callback function.
Syntax
FormListDeleteText(hForm, hField, Text)
hForm:
The form handle, returned from the FormNew() function. The form handle identifies the table where all data on the associated form is stored.
hField:
The field handle of the field currently selected.
Text:
The text to delete.
Return Value
0 (zero) if successful, otherwise an error is returned.
Related Functions
FormListSelectText, FormListAddText
Example
/* create a form with a list */
hForm = FormNew("Ingredients", 40, 10, 1);
hField = FormListBox(2,2,20,5,sBuf);
FormAddList("Flour");
FormAddList("Water");
FormAddList("Salt");
FormAddList("Sugar");
/* Display the form */
FormRead(1);
..
/*Remove Sugar from the list */
FormListDeleteText(hForm, hField, "Sugar");
..
See Also