WireLess Studio Widgets Developer's Guide |
This methods retrieves the text displayed by a cell on a WS_LIST_CTRL widget.
BSTR GetRowTextByName(LPCTSTR sObjectName, SHORT usRowIndex, SHORT usColumnIndex);
BSTR GetRowTextById(SHORT usObjectId, SHORT usRowIndex, SHORT usColumnIndex);
On success, GetRowText returns the text displayed by the target cell. On error GetSelectedItem returns an empty string. To get extended information, call WStError::GetLastErrorCode.
using WirelessStudioOleWidgets; WStWidget oWidget = new WStWidget(); short sListCtrlId= 4; oFactory.CreateWidgetById((short)WSTFactoryConstants.WS_LIST_CTRL, sListCtrlId, "", 0,0, 50, 50, ""); oWidget.AddColumById(sListCtrlId, 40, "Product Id"); oWidget.AddRowById(sListCtrlId, 0); oWidget.SetRowTextById(sListCtrlId, 0, 0, "44123"); string sText = oWidget.GetRowTextById(sListCtrlId, 0, 0);
Public wsWidget As New WStWidget ... Case "newRowTextField" sEventValue = wsForm.GetLastEventStrValue() 'Changes the text of the first column of a previously selected row If wsWidget.GetSelectedItemByName("myListCtrl") <> -1 Then wsWidget.SetRowTextByName "myListCtrl", wsWidget.GetSelectedItemByName("myListCtrl"), _ 0, sEventValue End If ...
AddColumn | ClearColumns | SetRowText | SetRowIcon | AddRow | ClearRows | ReadRowsFromFile | SetLoadMode | GetSelectedItem
WStWiget class reference | WStForm class reference | WStFactory class reference | WStError class reference
WireLess Studio by SofToGo S.A. | Visit our site www.softogo.com | Contact us help@softogo.com |