hi,
how can i find out which Control are Child OF oWnd
oMain:aControls = {TSAY,TCOMBOBOX,TFOLDER,TCOMBOBOX,TFOLDER,TSPLITTER, ...}
FOR ii := 1 TO LEN(oMain:aControls)
Object := oMain:aControls[ii]
DO CASE
CASE Object:isDerivedFrom("TSAY") // Xbase++ Syntax
Object:SetPos()
Object:SetSize()
// TSAY
oMain:aControls[1]:SETTEXT("hello world")
// TCOMBOBOX
oMain:aControls[2]:Select(3) // 3rd Item
MsgInfo( oControl:isDerivedFrom( "TWINDOW" ) )
Antonio Linares wrote:Harbour supports isDerivedFrom also:
- Code: Select all Expand view
MsgInfo( oControl:isDerivedFrom( "TWINDOW" ) )
oMain:aControls = {TSAY,TCOMBOBOX,TFOLDER,TCOMBOBOX,TFOLDER,TSPLITTER,TBUTTON, ... }
x := hb_valToExp(oMain:aControls[ii])
__itemSetObj( __itemSetRef( {{HWND, 394868}, {NOLDPROC, 4294903408}, {CCAPTION, }, {CVARNAME, oSayActive}, {NID, 102}, {TWINDOW:NTOP, 864}, {TWINDOW:NLEFT, 10}, {NBOTTOM, 893}, {NRIGHT, 649.00}, {NSTYLE, 1342177280}, {NCLRPANE, 16777215}, {NCLRTEXT, 0}, {ACONTROLS, {}}, {OBRUSH, {{HBRUSH, 9437200}, {HBITMAP, 0}, {HBMPORGL, 0}, {NCOUNT, 6}, {NRGBCOLOR, 16777215}, {LSYSTEM, .T.}, {USOURCE, CLR_WHITE}}}, {OFONT, {{CFACENAME, TAHOMA}, {HFONT, 1242174205}, {HFONTOLD, 0}, {LBOLD, .F.}, {LITALIC, .F.}, {LUNDERLINE, .F.}, {LSTRIKEOUT, .F.}, {NINPHEIGHT, -20}, {NINPWIDTH, 0}, {NESCAPEMENT, 0}, {NORIENTATION, 0}, {NWEIGHT, 0}, {NCHARSET, 0}, {NOUTPRECISION, 0}, {NCLIPPRECISION, 0}, {NQUALITY, 0}, {NPITCHFAMILY, 0}, {NCOUNT, 27}, {LDESTROY, .T.}, {LNEW, .F.}}} , ...
Return to FiveWin for Harbour/xHarbour
Users browsing this forum: No registered users and 101 guests