topic
stringlengths
1
63
text
stringlengths
1
577k
combobox for mod harbour
Hello Mark, thank you for your help. I don't think I can solve this problem right now. I'm still too inexperienced with javascript. I will post the code here, and on SLACK maybe someone will help us. But working with mod harbor is so exciting. Did you see that signing works too? Best regards Otto
combobox for mod harbour
Otto, Indead, signing works on both Chrome an Edge for me. Very nice <!-- s8) --><img src="{SMILIES_PATH}/icon_cool.gif" alt="8)" title="Cool" /><!-- s8) -->
combobox in a browse column
Anybody have sample source of having a combobox in a column on a TCBrowse. Where the user could simply change the value of the combobox just by clicking on it. I haven't even tried, I don't know where to start. Thanks,
combobox in a browse column
This is an old sample of mine. I don't remember if it is full working but at least the combobox works. Feel free to cannibalize it. [code=fw:i7th0z82]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"Fivewin.ch"</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"TCBrowse.ch"</span><br /><br /><br /><span style="color: #00C800;">FUNCTION</span> MAIN<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">LOCAL</span> oDlg, oBrw<br /><br />    SET CENTURY <span style="color: #0000ff;">ON</span><br />    SET DATE BRITISH<br /><br />    <span style="color: #00C800;">IF</span> !FILE<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"TESTEDCO.DBF"</span> <span style="color: #000000;">&#41;</span><br />        DBCREATE<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"TESTEDCO"</span>, <span style="color: #000000;">&#123;</span> <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"CARATTERE"</span>, <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">30</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>,;<br />                                <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"NUMERO"</span>,    <span style="color: #ff0000;">"N"</span>, <span style="color: #000000;">10</span>, <span style="color: #000000;">2</span> <span style="color: #000000;">&#125;</span>,;<br />                                <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"DATA"</span>,      <span style="color: #ff0000;">"D"</span>,  <span style="color: #000000;">8</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>,;<br />                                <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"MEMO"</span>,      <span style="color: #ff0000;">"M"</span>, <span style="color: #000000;">10</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span><br /><br />        USE TESTEDCO<br /><br />        APPEND BLANK<br />        APPEND BLANK<br /><br />        CLOSE<br />    <span style="color: #00C800;">ENDIF</span><br /><br />    USE TESTEDCO<br /><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">800</span>, <span style="color: #000000;">600</span><br /><br />    @ <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> BROWSE oBrw<br /><br />    oBrw:<span style="color: #000000;">bLogicLen</span> = <span style="color: #000000;">&#123;</span> || <span style="color: #000000;">&#40;</span> oBrw:<span style="color: #000000;">cAlias</span> <span style="color: #000000;">&#41;</span> -> <span style="color: #000000;">&#40;</span> OrdKeyCount<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br /><br />    oBrw:<span style="color: #000000;">bLDblClick</span> = <span style="color: #000000;">&#123;</span> || Modifica<span style="color: #000000;">&#40;</span> oBrw <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />    oBrw:<span style="color: #000000;">bKeyDown</span>   = <span style="color: #000000;">&#123;</span> | nKey | <span style="color: #00C800;">If</span><span style="color: #000000;">&#40;</span> nKey = VK_RETURN, Modifica<span style="color: #000000;">&#40;</span> oBrw <span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br /><br />    ADD COLUMN <span style="color: #0000ff;">TO</span> oBrw;<br />        <span style="color: #00C800;">DATA</span> TESTEDCO -> carattere;<br />        HEADER <span style="color: #ff0000;">"CARATTERE"</span>;<br />        <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">200</span><br /><br />    ADD COLUMN <span style="color: #0000ff;">TO</span> oBrw;<br />        <span style="color: #00C800;">DATA</span> TESTEDCO -> numero;<br />        HEADER <span style="color: #ff0000;">"NUMERO"</span>;<br />        <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@EZ 9,999,999.99"</span>;<br />        <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span> <span style="color: #0000ff;">RIGHT</span><br /><br />    ADD COLUMN <span style="color: #0000ff;">TO</span> oBrw;<br />        <span style="color: #00C800;">DATA</span> TESTEDCO -> <span style="color: #00C800;">data</span>;<br />        HEADER <span style="color: #ff0000;">"DATA"</span>;<br />        <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span><br /><br />    ADD COLUMN <span style="color: #0000ff;">TO</span> oBrw;<br />        <span style="color: #00C800;">DATA</span> STRTRAN<span style="color: #000000;">&#40;</span> TESTEDCO -> memo, CRLF, <span style="color: #ff0000;">" "</span> <span style="color: #000000;">&#41;</span>;<br />        HEADER <span style="color: #ff0000;">"MEMO"</span>;<br />        <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span><br /><br /><span style="color: #B900B9;">//    ADD COLUMN TO oBrw</span><br /><br />    oBrw:<span style="color: #000000;">lCellStyle</span> = .T.<br /><br />    <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg;<br />             <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">INIT</span> oDlg:<span style="color: #000000;">SetControl</span><span style="color: #000000;">&#40;</span> oBrw <span style="color: #000000;">&#41;</span>;<br />             <span style="color: #0000ff;">CENTER</span><br /><br />    CLOSE<br /><br />    <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> MODIFICA<span style="color: #000000;">&#40;</span> oBrw <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">LOCAL</span> nCol := oBrw:<span style="color: #000000;">nColAct</span><br /><br />    <span style="color: #00C800;">LOCAL</span> xVar := EVAL<span style="color: #000000;">&#40;</span> oBrw:<span style="color: #000000;">aColumns</span><span style="color: #000000;">&#91;</span> nCol <span style="color: #000000;">&#93;</span>:<span style="color: #000000;">bData</span> <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">LOCAL</span> xRes<br /><br />    <span style="color: #00C800;">IF</span> xVar = <span style="color: #00C800;">NIL</span>; <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span>; <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> nCol = <span style="color: #000000;">4</span><br />        xVar = FIELDGET<span style="color: #000000;">&#40;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#41;</span><br /><br />        <span style="color: #00C800;">IF</span> EDITMEMO<span style="color: #000000;">&#40;</span> oBrw, @xVar <span style="color: #000000;">&#41;</span><br />            <span style="color: #00C800;">IF</span> RLOCK<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />                FIELDPUT<span style="color: #000000;">&#40;</span> <span style="color: #000000;">4</span>, xVar <span style="color: #000000;">&#41;</span><br />                oBrw:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span> .F. <span style="color: #000000;">&#41;</span><br />            <span style="color: #00C800;">ENDIF</span><br />        <span style="color: #00C800;">ENDIF</span><br /><br />        <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> nCol = <span style="color: #000000;">1</span><br /><span style="color: #B900B9;">//        IF EDITCOL( oBrw, nCol, 250, @xVar, , CLR_WHITE, CLR_GREEN )</span><br /><span style="color: #B900B9;">//        IF EDITCOL( oBrw, nCol, , @xVar, "Init", CLR_WHITE, CLR_GREEN )</span><br /><br />        xRes = EDITCOL<span style="color: #000000;">&#40;</span> oBrw, nCol, , @xVar, , CLR_WHITE, CLR_GREEN, <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"Pippo"</span>, <span style="color: #ff0000;">"Pluto"</span>, <span style="color: #ff0000;">"Paperino"</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span><br /><span style="color: #B900B9;">//        xRes = EDITCOL( oBrw, nCol, , @xVar, , CLR_WHITE, CLR_GREEN, , { || MsgInfo( "bAction1" ) }, { || MsgInfo( "bAction2" ) } )</span><br /><br />        <span style="color: #00C800;">IF</span> VALTYPE<span style="color: #000000;">&#40;</span> xRes <span style="color: #000000;">&#41;</span> = <span style="color: #ff0000;">"B"</span><br />            EVAL<span style="color: #000000;">&#40;</span> xRes <span style="color: #000000;">&#41;</span><br />        <span style="color: #00C800;">ELSE</span><br />            <span style="color: #00C800;">IF</span> RLOCK<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />                FIELDPUT<span style="color: #000000;">&#40;</span> nCol, xVar <span style="color: #000000;">&#41;</span><br />                oBrw:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span> .F. <span style="color: #000000;">&#41;</span><br />            <span style="color: #00C800;">ENDIF</span><br />        <span style="color: #00C800;">ENDIF</span><br />    <span style="color: #00C800;">ELSE</span><br />        <span style="color: #00C800;">IF</span> EDITCOL<span style="color: #000000;">&#40;</span> oBrw, nCol, , @xVar, , CLR_WHITE, CLR_GREEN <span style="color: #000000;">&#41;</span><br />            <span style="color: #00C800;">IF</span> RLOCK<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />                FIELDPUT<span style="color: #000000;">&#40;</span> nCol, xVar <span style="color: #000000;">&#41;</span><br />                oBrw:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span> .F. <span style="color: #000000;">&#41;</span><br />            <span style="color: #00C800;">ENDIF</span><br />        <span style="color: #00C800;">ENDIF</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> EDITCOL<span style="color: #000000;">&#40;</span> oBrw, nCol, nWidth, xVar, cInit, nClrText, nClrBack, aList, bAction1, bAction2 <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">LOCAL</span> oDlg, oGet, oCbx, oBtn1, oBtn2<br /><br />    <span style="color: #00C800;">LOCAL</span> cTyp := VALTYPE<span style="color: #000000;">&#40;</span> xVar <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">LOCAL</span> cPic := oBrw:<span style="color: #000000;">aColumns</span><span style="color: #000000;">&#91;</span> nCol <span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cPicture</span><br />    <span style="color: #00C800;">LOCAL</span> nAli := oBrw:<span style="color: #000000;">aColumns</span><span style="color: #000000;">&#91;</span> nCol <span style="color: #000000;">&#93;</span>:<span style="color: #000000;">nAlign</span><br /><br />    <span style="color: #00C800;">LOCAL</span> nStartCol := <span style="color: #000000;">0</span><br /><br />    <span style="color: #00C800;">LOCAL</span> aDim<br /><br />    <span style="color: #00C800;">LOCAL</span> xRes := .F.<br /><br />    <span style="color: #00C800;">LOCAL</span> xTmp := xVar<br /><br />    <span style="color: #00C800;">LOCAL</span> lClose := .F.<br /><br />    <span style="color: #00C800;">LOCAL</span> i<br /><br />    <span style="color: #00C800;">IF</span> oBrw:<span style="color: #000000;">nFreeze</span> > <span style="color: #000000;">0</span><br />        <span style="color: #00C800;">FOR</span> i = <span style="color: #000000;">1</span> <span style="color: #0000ff;">TO</span> <span style="color: #0000ff;">MIN</span><span style="color: #000000;">&#40;</span> oBrw:<span style="color: #000000;">nFreeze</span>, nCol - <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span><br />            nStartCol += oBrw:<span style="color: #000000;">GetColSizes</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#91;</span> i <span style="color: #000000;">&#93;</span><br />        <span style="color: #00C800;">NEXT</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">FOR</span> i = oBrw:<span style="color: #000000;">nColPos</span> <span style="color: #0000ff;">TO</span> nCol - <span style="color: #000000;">1</span><br />        nStartCol += oBrw:<span style="color: #000000;">aColSizes</span><span style="color: #000000;">&#91;</span> i <span style="color: #000000;">&#93;</span><br />    <span style="color: #00C800;">NEXT</span><br /><br />    aDim = ATCBRWPOSRECT<span style="color: #000000;">&#40;</span> oBrw:<span style="color: #000000;">hWnd</span>, oBrw:<span style="color: #000000;">nRowPos</span>, nStartCol, oBrw:<span style="color: #000000;">aColSizes</span><span style="color: #000000;">&#91;</span> nCol <span style="color: #000000;">&#93;</span>, <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> oBrw:<span style="color: #000000;">oFont</span> != <span style="color: #00C800;">NIL</span>, oBrw:<span style="color: #000000;">oFont</span>:<span style="color: #000000;">hFont</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg;<br />           <span style="color: #0000ff;">STYLE</span> WS_POPUP<br /><br />    oDlg:<span style="color: #000000;">bLostFocus</span> = <span style="color: #000000;">&#123;</span> || oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br /><br />    <span style="color: #00C800;">DO</span> <span style="color: #00C800;">CASE</span><br />        <span style="color: #00C800;">CASE</span> !EMPTY<span style="color: #000000;">&#40;</span> aList <span style="color: #000000;">&#41;</span><br />            @ <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #0000ff;">COMBOBOX</span> oCbx <span style="color: #0000ff;">VAR</span> xTmp;<br />                   <span style="color: #0000ff;">ITEMS</span> aList;<br />                   <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span> <span style="color: #000000;">&#40;</span> oCbx:<span style="color: #000000;">Close</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, xRes := .T., oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />                   <br />        <span style="color: #00C800;">CASE</span> cTyp = <span style="color: #ff0000;">"C"</span> .OR. cTyp = <span style="color: #ff0000;">"D"</span><br />            @ <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #0000ff;">GET</span> oGet <span style="color: #0000ff;">VAR</span> xTmp;<br />                   <span style="color: #0000ff;">COLOR</span> nClrText, nClrBack;<br />                   <span style="color: #0000ff;">PICTURE</span> cPic<br /><br />            oGet:<span style="color: #000000;">nStyle</span> = NAND<span style="color: #000000;">&#40;</span> oGet:<span style="color: #000000;">nStyle</span>, NNOT<span style="color: #000000;">&#40;</span> WS_BORDER <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br /><br />            oGet:<span style="color: #000000;">bKeyDown</span> = <span style="color: #000000;">&#123;</span> | nKey | <span style="color: #00C800;">If</span><span style="color: #000000;">&#40;</span> nKey = VK_RETURN, <span style="color: #000000;">&#40;</span> oGet:<span style="color: #000000;">Assign</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, xRes := .T., oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />        <span style="color: #00C800;">CASE</span> cTyp = <span style="color: #ff0000;">"N"</span><br />            @ <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #0000ff;">GET</span> oGet <span style="color: #0000ff;">VAR</span> xTmp;<br />                   <span style="color: #0000ff;">COLOR</span> nClrText, nClrBack;<br />                   <span style="color: #0000ff;">PICTURE</span> STRTRAN<span style="color: #000000;">&#40;</span> cPic, <span style="color: #ff0000;">","</span>, <span style="color: #ff0000;">""</span> <span style="color: #000000;">&#41;</span>;<br />                   <span style="color: #0000ff;">RIGHT</span><br /><br />            oGet:<span style="color: #000000;">nStyle</span> = NAND<span style="color: #000000;">&#40;</span> oGet:<span style="color: #000000;">nStyle</span>, NNOT<span style="color: #000000;">&#40;</span> WS_BORDER <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br /><br />            oGet:<span style="color: #000000;">bKeyDown</span> = <span style="color: #000000;">&#123;</span> | nKey | <span style="color: #00C800;">If</span><span style="color: #000000;">&#40;</span> nKey = VK_RETURN, <span style="color: #000000;">&#40;</span> oGet:<span style="color: #000000;">Assign</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, xRes := .T., oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />    <span style="color: #00C800;">ENDCASE</span><br /><br />    <span style="color: #00C800;">IF</span> oGet != <span style="color: #00C800;">NIL</span> .AND. !EMPTY<span style="color: #000000;">&#40;</span> cInit <span style="color: #000000;">&#41;</span><br />        oDlg:<span style="color: #000000;">bStart</span> = <span style="color: #000000;">&#123;</span> || PostString<span style="color: #000000;">&#40;</span> oGet, cInit <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> bAction1 != <span style="color: #00C800;">NIL</span><br />        @ <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #0000ff;">BTNBMP</span> oBtn1;<br />               FILE <span style="color: #ff0000;">"EDITCOL1.BMP"</span>;<br /><span style="color: #B900B9;">//               NOBORDER</span><br /><br />        oBtn1:<span style="color: #000000;">bAction</span>  = <span style="color: #000000;">&#123;</span> || xRes := bAction1, oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />        oBtn1:<span style="color: #000000;">cTooltip</span> = <span style="color: #ff0000;">"Questo è il tooltip 1"</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> bAction2 != <span style="color: #00C800;">NIL</span><br />        @ <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #0000ff;">BTNBMP</span> oBtn2;<br />               FILE <span style="color: #ff0000;">"EDITCOL2.BMP"</span>;<br /><span style="color: #B900B9;">//               NOBORDER</span><br /><br />        oBtn2:<span style="color: #000000;">bAction</span>  = <span style="color: #000000;">&#123;</span> || xRes := bAction2, oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />        oBtn2:<span style="color: #000000;">cTooltip</span> = <span style="color: #ff0000;">"Questo è il tooltip 2"</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg;<br />             <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">INIT</span> DLGADJUST<span style="color: #000000;">&#40;</span> oDlg, oGet, oCbx, oBtn1, oBtn2, nWidth, aDim, cTyp <span style="color: #000000;">&#41;</span>;<br />             <span style="color: #0000ff;">VALID</span> lClose := .T.;<br />             NOMODAL<br /><br />    STOPUNTIL<span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#123;</span> || lClose <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">IF</span> VALTYPE<span style="color: #000000;">&#40;</span> xRes <span style="color: #000000;">&#41;</span> != <span style="color: #ff0000;">"B"</span><br />        <span style="color: #00C800;">IF</span> xTmp = xVar; xRes = .F.; <span style="color: #00C800;">ENDIF</span><br />        xVar = xTmp<br />    <span style="color: #00C800;">ENDIF</span><br /><br />    oBrw:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">RETURN</span> xRes<br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> POSTSTRING<span style="color: #000000;">&#40;</span> oGet, cString <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">LOCAL</span> i<br /><br />    <span style="color: #00C800;">FOR</span> i = <span style="color: #000000;">1</span> <span style="color: #0000ff;">TO</span> LEN<span style="color: #000000;">&#40;</span> cString <span style="color: #000000;">&#41;</span><br />        POSTMESSAGE<span style="color: #000000;">&#40;</span> oGet:<span style="color: #000000;">hWnd</span>, WM_CHAR, <span style="color: #0000ff;">ASC</span><span style="color: #000000;">&#40;</span> <span style="color: #0000ff;">SUBSTR</span><span style="color: #000000;">&#40;</span> cString, i, <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">NEXT</span><br /><br />    <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> DLGADJUST<span style="color: #000000;">&#40;</span> oDlg, oGet, oCbx, oBtn1, oBtn2, nWidth, aDim, cType <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">DEFAULT</span> nWidth := aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span><br /><br />    <span style="color: #00C800;">IF</span> oCbx != <span style="color: #00C800;">NIL</span><br />        oDlg:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> + <span style="color: #000000;">1</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> + <span style="color: #000000;">1</span>, nWidth + <span style="color: #000000;">2</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> + <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span><br />    ELSEIF cType = <span style="color: #ff0000;">"C"</span> .OR. cType = <span style="color: #ff0000;">"D"</span><br />        oDlg:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> + <span style="color: #000000;">2</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> + <span style="color: #000000;">3</span>, nWidth - <span style="color: #000000;">2</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> - <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span><br />    ELSEIF cType = <span style="color: #ff0000;">"N"</span><br />        oDlg:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> + <span style="color: #000000;">2</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> + <span style="color: #000000;">2</span>, nWidth - <span style="color: #000000;">1</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> - <span style="color: #000000;">1</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> oBtn1 != <span style="color: #00C800;">NIL</span> .AND. oBtn2 != <span style="color: #00C800;">NIL</span><br />        nWidth -= <span style="color: #000000;">33</span><br />    ELSEIF oBtn1 != <span style="color: #00C800;">NIL</span> .OR. oBtn2 != <span style="color: #00C800;">NIL</span><br />        nWidth -= <span style="color: #000000;">17</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> oGet != <span style="color: #00C800;">NIL</span><br />        oGet:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, nWidth, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> oCbx != <span style="color: #00C800;">NIL</span><br />        oCbx:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">-3</span>, <span style="color: #000000;">-1</span>, nWidth + <span style="color: #000000;">4</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> oBtn1 != <span style="color: #00C800;">NIL</span> .AND. oBtn2 != <span style="color: #00C800;">NIL</span><br />        oBtn1:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">-1</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> - <span style="color: #000000;">33</span>, <span style="color: #000000;">16</span>, <span style="color: #000000;">16</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> oBtn1 != <span style="color: #00C800;">NIL</span> .AND. oBtn2 = <span style="color: #00C800;">NIL</span><br />        oBtn1:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">-1</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> - <span style="color: #000000;">17</span>, <span style="color: #000000;">16</span>, <span style="color: #000000;">16</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> oBtn2 != <span style="color: #00C800;">NIL</span><br />        oBtn2:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">-1</span>, aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span> - aDim<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> - <span style="color: #000000;">17</span>, <span style="color: #000000;">16</span>, <span style="color: #000000;">16</span> <span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> EDITMEMO<span style="color: #000000;">&#40;</span> oBrw, cVar <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">LOCAL</span> oDlg, oGet<br /><br />    <span style="color: #00C800;">LOCAL</span> lMod := .T.<br /><br />    <span style="color: #00C800;">LOCAL</span> cTmp := cVar<br /><br />    <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg;<br />           <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">800</span>, <span style="color: #000000;">600</span><br /><br />    @ <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #0000ff;">GET</span> oGet <span style="color: #0000ff;">VAR</span> cTmp MEMO<br /><br />    @ <span style="color: #000000;">15.5</span>, <span style="color: #000000;">2</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #ff0000;">"&Conferma"</span>;<br />              <span style="color: #0000ff;">ACTION</span> oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span> IDOK <span style="color: #000000;">&#41;</span><br /><br />    @ <span style="color: #000000;">15.5</span>, <span style="color: #000000;">12</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #ff0000;">"&Annulla"</span>;<br />               <span style="color: #0000ff;">ACTION</span> oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />    oDlg:<span style="color: #000000;">bStart</span> = <span style="color: #000000;">&#123;</span> || oGet:<span style="color: #000000;">SetPos</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br /><br />    <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg;<br />             <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">INIT</span> MEMOADJUST<span style="color: #000000;">&#40;</span> oDlg, oGet <span style="color: #000000;">&#41;</span>;<br />             <span style="color: #0000ff;">CENTER</span><br /><br />    <span style="color: #00C800;">IF</span> oDlg:<span style="color: #000000;">nResult</span> = IDCANCEL; <span style="color: #00C800;">RETURN</span> .F.; <span style="color: #00C800;">ENDIF</span><br /><br />    <span style="color: #00C800;">IF</span> cTmp == cVar; lMod = .F.; <span style="color: #00C800;">ENDIF</span><br /><br />    cVar = cTmp<br /><br />    oBrw:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">RETURN</span> lMod<br /><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> MEMOADJUST<span style="color: #000000;">&#40;</span> oDlg, oGet <span style="color: #000000;">&#41;</span><br /><br />    oGet:<span style="color: #0000ff;">Move</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, oDlg:<span style="color: #000000;">nWidth</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> - <span style="color: #000000;">20</span>, oDlg:<span style="color: #000000;">nHeight</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> - <span style="color: #000000;">100</span> <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span></div>[/code:i7th0z82] EMG
combobox indices y datos ...
Hola. Quiero mostrar datos de una consulta en Mariadb en un combobox, la consulta me devuelve 2 campos: el id y el nombre del cliente. quiero que en el combobox solo me devuelva el nombre PERO que despues pueda usar el id de ese nombre (por ejemplo para llamar a los datos del cliente). Como puedo hacer para "ocultar" el id en el combobox y que solo me muestre el campo "nombre"? [code=fw:32ddq5bt]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">METHOD</span> listaClientes<span style="color: #000000;">&#40;</span> oGets, vGets <span style="color: #000000;">&#41;</span> <span style="color: #00C800;">CLASS</span> TArbol<br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oCliente := TCliente<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #00C800;">new</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oRegistros<br /><br />&nbsp; &nbsp;oCliente:<span style="color: #000000;">oCnx</span> := ::<span style="color: #000000;">oCnx</span><br /><br />&nbsp; &nbsp;oRegistros := oCliente:<span style="color: #000000;">listaClientes</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;::<span style="color: #000000;">aListaClientes</span> := oRegistros:<span style="color: #000000;">GETRows</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;oGets<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span>:<span style="color: #000000;">setitems</span><span style="color: #000000;">&#40;</span> arrTranspose<span style="color: #000000;">&#40;</span> ::<span style="color: #000000;">aListaClientes</span> <span style="color: #000000;">&#41;</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;oGets<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span>:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">RETURN</span> <span style="color: #000000;">&#40;</span> <span style="color: #00C800;">NIL</span> <span style="color: #000000;">&#41;</span><br />&nbsp;</div>[/code:32ddq5bt] Si hago de esta forma tengo que almacenar en un array y despues en el boton de acceso a los datos que seleccione del combobox tengo que leer el array por un :nAt del combobox, lo que quisiera es no tener que hacer eso, directamente que cuando seleccione del combobox me devuelva la columna del "indice" gracias.
combobox indices y datos ...
Hola buenas noches como vas? Eso lo puedes hacer fácilmente con dbcombo [url:1er7m2i8]https&#58;//forums&#46;fivetechsupport&#46;com/viewtopic&#46;php?f=6&t=41317&p=247455&hilit=dbcombo&sid=12e17b3acf511a14a2afd4cfa89faf8d&sid=8f6fae056078caff035794484337c08b#p247455[/url:1er7m2i8]
combobox inside a list box
I want every field in a list box entered via combobox of fixed entries . How can I implement that control ?
combobox inside a list box
Ehab, samples\TestLbx.prg shows how to dinamically add new items to a listbox. samples\combos.prg shows how to use combos ON CHANGE event. Combine both concepts and you can do what you are looking for.
combobox issue
Dear all, I have a problem when using a combobox. Here my prg file: [code=fw:24razuwx]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"FiveWin.ch"</span><br /><br /><span style="color: #00C800;">FUNCTION</span> Main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">LOCAL</span> aMwSt := <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"19"</span>, <span style="color: #ff0000;">"7"</span>, <span style="color: #ff0000;">"0"</span> <span style="color: #000000;">&#125;</span><br /><span style="color: #00C800;">LOCAL</span> aTest   := aPosArtEdit<span style="color: #000000;">&#40;</span> aMwSt, <span style="color: #ff0000;">"19"</span> <span style="color: #000000;">&#41;</span><br /><br />   xbrowser<span style="color: #000000;">&#40;</span> aTest <span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">RETURN</span><span style="color: #000000;">&#40;</span> <span style="color: #00C800;">NIL</span> <span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">FUNCTION</span> aPosArtEdit<span style="color: #000000;">&#40;</span> aMwSt, cPos <span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">LOCAL</span> oDlg, oGet, cGet, oCbx, cCbx<br /><span style="color: #00C800;">LOCAL</span> aItems := <span style="color: #000000;">&#123;</span><span style="color: #000000;">&#125;</span><br /><span style="color: #00C800;">LOCAL</span> aRet   := <span style="color: #000000;">&#123;</span><span style="color: #000000;">&#125;</span><br /><br />   XBROWSER aMwStSaetze <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"array given to function"</span><br /><br />   cGet := <span style="color: #ff0000;">"Leistung xyz"</span><br />   cCbx := padl<span style="color: #000000;">&#40;</span> cPos, <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">" %"</span><br /><br />   aeval<span style="color: #000000;">&#40;</span> aMwSt, <span style="color: #000000;">&#123;</span> | u | aadd<span style="color: #000000;">&#40;</span> aItems, padl<span style="color: #000000;">&#40;</span> u, <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">" %"</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span><br /><br />   XBROWSER aItems <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"array is now like this"</span><br />   <span style="color: #0000ff;">msginfo</span><span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"looking for cCbx = "</span> + cCbx + CRLF + CRLF + <span style="color: #ff0000;">"found on array position : "</span> + str<span style="color: #000000;">&#40;</span> ascan<span style="color: #000000;">&#40;</span> aItems, cCbx <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br /><br />   <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"EDIT_POS"</span><br /><br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">GET</span> oGet <span style="color: #0000ff;">VAR</span> cGet <span style="color: #0000ff;">ID</span> <span style="color: #000000;">10</span> <span style="color: #0000ff;">OF</span> oDlg<br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">COMBOBOX</span> oCbx <span style="color: #0000ff;">VAR</span> cCbx <span style="color: #0000ff;">ITEMS</span> aItems <span style="color: #0000ff;">ID</span> <span style="color: #000000;">20</span> <span style="color: #0000ff;">OF</span> oDlg<br /><br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">30</span> <span style="color: #0000ff;">OF</span> oDlg  <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> aRet := <span style="color: #000000;">&#123;</span> cGet, oCbx:<span style="color: #000000;">nAt</span> <span style="color: #000000;">&#125;</span>,  oDlg:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br /><br />   <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg<br /><span style="color: #00C800;">RETURN</span><span style="color: #000000;">&#40;</span> aRet <span style="color: #000000;">&#41;</span><br /> </div>[/code:24razuwx] And here my rc file: [code=fw:24razuwx]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <windows.h><br /><span style="color: #00D7D7;">#include</span> <commctrl.h><br /><br />LANGUAGE LANG_ENGLISH,SUBLANG_ENGLISH_US<br /><span style="color: #000000;">1</span> <span style="color: #000000;">24</span> <span style="color: #ff0000;">"WindowsXP.Manifest"</span><br /><br />EDIT_POS <span style="color: #0000ff;">DIALOG</span> DISCARDABLE <span style="color: #000000;">6</span>, <span style="color: #000000;">18</span>, <span style="color: #000000;">322</span>, <span style="color: #000000;">142</span><br /><span style="color: #0000ff;">STYLE</span> WS_THICKFRAME|WS_CAPTION|WS_SYSMENU|WS_MINIMIZEBOX|WS_MAXIMIZEBOX|WS_VISIBLE<br />CAPTION <span style="color: #ff0000;">"Define MwSt"</span><br /><span style="color: #0000ff;">FONT</span> <span style="color: #000000;">10</span>, <span style="color: #ff0000;">"MS Sans Serif"</span><br /><span style="color: #000000;">&#123;</span><br />  CONTROL <span style="color: #ff0000;">"Description"</span>, <span style="color: #000000;">-1</span>, <span style="color: #ff0000;">"Static"</span>, WS_GROUP, <span style="color: #000000;">16</span>, <span style="color: #000000;">28</span>, <span style="color: #000000;">95</span>, <span style="color: #000000;">8</span><br />  CONTROL <span style="color: #ff0000;">""</span>, <span style="color: #000000;">10</span>, <span style="color: #ff0000;">"Edit"</span>, WS_BORDER|WS_TABSTOP, <span style="color: #000000;">16</span>, <span style="color: #000000;">40</span>, <span style="color: #000000;">248</span>, <span style="color: #000000;">12</span><br />  CONTROL <span style="color: #ff0000;">""</span>, <span style="color: #000000;">20</span>, <span style="color: #ff0000;">"ComboBox"</span>, WS_BORDER|CBS_DROPDOWN|CBS_SORT|WS_VSCROLL|WS_TABSTOP, <span style="color: #000000;">16</span>, <span style="color: #000000;">72</span>, <span style="color: #000000;">48</span>, <span style="color: #000000;">52</span><br />  CONTROL <span style="color: #ff0000;">"MwSt-Satz"</span>, <span style="color: #000000;">-1</span>, <span style="color: #ff0000;">"Static"</span>, WS_GROUP, <span style="color: #000000;">16</span>, <span style="color: #000000;">60</span>, <span style="color: #000000;">40</span>, <span style="color: #000000;">8</span><br />  CONTROL <span style="color: #ff0000;">"speichern"</span>, <span style="color: #000000;">30</span>, <span style="color: #ff0000;">"Button"</span>, WS_TABSTOP, <span style="color: #000000;">208</span>, <span style="color: #000000;">116</span>, <span style="color: #000000;">48</span>, <span style="color: #000000;">14</span><br /><span style="color: #000000;">&#125;</span><br /> </div>[/code:24razuwx] I can't find out why the combobox is showing the array items in reverse order. Does anyone know this behaviour? -Detlef
combobox issue
Just remove CBS_SORT from your RC file. EMG
combobox issue
Many thanks, Enrico. I really should have read the rc file carefully. <!-- s:oops: --><img src="{SMILIES_PATH}/icon_redface.gif" alt=":oops:" title="Embarassed" /><!-- s:oops: --> -Detlef
combobox me devuelve datos no correctos
Hola. Si el combobox lo tengo en un .res y en ese .res la variable SORT esta seteada a "SI" cuando se ejecuta oComboBox:bChange:= { || msginfo(vCombo) } el valor que me muestra es el correspondiente a aItems[indice - 1]. en vez de devolverme aItems[indice] Ejemplo: Si estoy sobre el elemento "DOS" en vez de mostrarme DOS me muestra UNO Si en el .res a SORT lo seteo en "NO" esto no ocurre y me devuelve "DOS" gracias. [code=fw:eek8f3hl]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">FUNCTION</span> main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">LOCAL</span> oDlg,;<br />      oCombo, vCombo,;<br />      aItems<br />      aItems:=<span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">""</span>, <span style="color: #ff0000;">"uno"</span>, <span style="color: #ff0000;">"dos"</span>, <span style="color: #ff0000;">"tres"</span><span style="color: #000000;">&#125;</span><br />      <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">resource</span> <span style="color: #ff0000;">"DLG01"</span><br />           <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">COMBOBOX</span> oCombo <span style="color: #0000ff;">VAR</span> vCombo <span style="color: #0000ff;">ID</span> <span style="color: #000000;">200</span> <span style="color: #0000ff;">OF</span> oDlg<br />           oCombo:<span style="color: #000000;">setItems</span><span style="color: #000000;">&#40;</span>aItems<span style="color: #000000;">&#41;</span><br />           oCombo:<span style="color: #000000;">bChange</span>:= <span style="color: #000000;">&#123;</span>|| <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span>vCombo<span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />       <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTERED</span><br /><span style="color: #00C800;">RETURN</span> <span style="color: #000000;">&#40;</span><span style="color: #00C800;">NIL</span><span style="color: #000000;">&#41;</span></div>[/code:eek8f3hl]
combobox me devuelve datos no correctos
Hola Goosfancito Lograte solucionar este problema, a mi se me esta presentando lo mismo y no he podido encontrar el error... agradeceria tu ayuda.. saludos
combobox me devuelve datos no correctos
.RC FLD_GENERAL_4 DIALOG 3, 43, 386, 192 STYLE DS_ABSALIGN | DS_MODALFRAME | 0x4L | WS_CHILD | WS_VISIBLE | WS_BORDER FONT 10, "MS Sans Serif" { COMBOBOX 31, 55, 112, 70, 11, CBS_DROPDOWNLIST | WS_TABSTOP COMBOBOX 32, 55, 125, 70, 19, CBS_DROPDOWNLIST | WS_TABSTOP } [code=fw:m0ld8dt6]<div class="fw" id="{CB}" style="font-family: monospace;"><br />&nbsp; &nbsp; <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">COMBOBOX</span> oCombo <span style="color: #0000ff;">VAR</span> XESTCIVIL <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@K!"</span> &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ITEMS</span> cEstCivil <span style="color: #0000ff;">ID</span> <span style="color: #000000;">31</span> <span style="color: #0000ff;">OF</span> oFld:<span style="color: #000000;">aDialogs</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">UPDATE</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;COLORS CLR_HRED, CLR_HCYAN &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ;<br /><br />&nbsp; &nbsp; <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">COMBOBOX</span> oCbxSit <span style="color: #0000ff;">VAR</span> XATIVO <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@K!"</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ITEMS</span> cSituacao <span style="color: #0000ff;">ID</span> <span style="color: #000000;">32</span> <span style="color: #0000ff;">OF</span> oFld:<span style="color: #000000;">aDialogs</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span> &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">UPDATE</span> COLORS CLR_HRED, CLR_HCYAN<br />&nbsp;</div>[/code:m0ld8dt6] 
combobox me devuelve datos no correctos
Hola Karinha No uso .RC, utilizo .RES
combobox me devuelve datos no correctos
Basta incorporar a tu .RES Baje e salve como TESTE.RC e llame tu editor de recursos e añade al .RES. Salu2.
combobox not open in windows mobile 6.5
I have here a problem which has put the forum a few months and still can not solve. The following example was tested on Windows emulator 6.5, and 6.1 #include "FWCE.ch" function Main() local oWnd, cValue :="One" DEFINE window oWnd TITLE "Combos" @ 1, 1 COMBOBOX cValue ITEMS { "One", "Two", "Three" } OF oWnd ACTIVATE window oWnd return nil in the 6.5 the combobox not open in thr 6.1 or 5.0 operate normally Any topic will be a great help. best Regards Sérgio
combobox not open in windows mobile 6.5
Pictures in the emulator WM6. in the 6.5 the combobox not open [img:1ia427q5]http&#58;//www&#46;briweb&#46;net/software/forum/wm6_5&#46;png[/img:1ia427q5] in thr 6.1 or 5.0 operate normally [img:1ia427q5]http&#58;//www&#46;briweb&#46;net/software/forum/wm6_1&#46;png[/img:1ia427q5] What is wrong?
combobox not open in windows mobile 6.5
Try [code=fw:231t048y]<div class="fw" id="{CB}" style="font-family: monospace;">@ <span style="color: #000000;">1</span>, <span style="color: #000000;">1</span> <span style="color: #0000ff;">COMBOBOX</span> cValue <span style="color: #0000ff;">ITEMS</span> <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"One"</span>, <span style="color: #ff0000;">"Two"</span>, <span style="color: #ff0000;">"Three"</span> <span style="color: #000000;">&#125;</span> <span style="color: #0000ff;">OF</span> oWnd <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">175</span>, <span style="color: #000000;">200</span></div>[/code:231t048y] EMG
combobox not open in windows mobile 6.5
Still does not work the combobox not open [img:34tcv8iy]http&#58;//www&#46;briweb&#46;net/software/forum/wm6_5_2&#46;png[/img:34tcv8iy] this image emulator - WM6.5 Professional emulator Square. the same happens on my phone HTC TOUCH Dimmond best regards Sérgio
combobox not open in windows mobile 6.5
I can not understand why this happens version of FWPPC ? compiler ? I developed a software using FWPPC, This has several combobox, my client is going to change equipment to windows Mobile 6.5 I'm in panic, because I still could not solve the problem. help me please, Antonio Linares and all users of FWPPC. Best Regards
combobox not open in windows mobile 6.5
Sergio, Please send me an email to <!-- e --><a href="mailto:alinares@fivetechsoft.com">alinares@fivetechsoft.com</a><!-- e --> and we may do a TeamViewer session and check what is going on, thanks
combobox not open in windows mobile 6.5
António, ainda não consegui resolver as combobox, tens mais alguma ideia? Sergio
combobox not open in windows mobile 6.5
Sergio, Already solved <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> <!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=7&t=15956&p=88946#p88946">viewtopic.php?f=7&t=15956&p=88946#p88946</a><!-- l -->
combobox not open in windows mobile 6.5
Thanks, that's OK. tested the emulator WM6.5 and in HTC Touch Dimond 2. worked without problems. Gracias, Obrigado, A Big Thanks Post this resolved <!-- s:) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":)" title="Smile" /><!-- s:) --> Best Regards Sérgio
combobox não encerra
Olá após atualizar para FWH 8.02 surgiu-me um problema: Nos diálogos aproveitados em vários relatórios, quando preciso encerrar um COMBOBOX eles deixaram de ser encerrados. ex.: REDEFINE COMBOBOX oList1 VAR matriz[3] ID 125 of oT430a ... ACTIVATE DIALOG oT430a NOWAIT VALID ( oT430a := nil, .t. ) ON INIT ( oList1:end() ) end() deixou de encerrar o combo Alguém sabe o motivo e como corrigir? []'s Rogerio
combobox não encerra
Exactamente no entiendo el caso, Pero; Tienes solo el combobox en el dialogo?
combobox não encerra
Adblanco no diálogo existem vários controles. Os Get's, say's, button's, etc., que mando encerrar (:end() ) são encerrados. Somente os combobox que deixaram de ser encerrados em todos os diálogos de todo o programa. Como aproveito um mesmo desenho de janela para vários relatórios, conforme o caso preciso encerrar determinados controles. []'s Rogerio
combobox não encerra
O Botão está com a clausula CANCEL Rogerio? Quando Voce valida, usa o comando GETASYNCKEY()? Ex: IF GETASYNCKEY( VK_UP ) RETURN( .F. ) ENDIF RETURN( .T. ) QUAL É O ESTILO DO COMBO QUE ESTAIS USANDO?
combobox não encerra
karinha estou usando o seguinte: CONTROL "", IDC_COMBOBOX4, "COMBOBOX", CBS_DROPDOWNLIST | WS_CHILD | WS_VISIBLE | WS_VSCROLL | WS_TABSTOP, 5, 75, 91, 87 []'s Rogerio
combobox não encerra
você podera oculta-lo, mas ficar na memoria usando o camento Hide() e para voltar a aparecer SHOW() REDEFINE COMBOBOX oObj ... oObj:Hide() ///ira oculta-lo
combobox não encerra
Rogerio, CBS_DROPDOWNLIST -> 16 Bits. CBS_DROPDOWN -> 32 Bits, automaticamente, o <enter< aciona-se. Abraços, porque não te vejo no FIVEWIN BRASIL?
combobox não encerra
Ronaldo Hide() funciona, obrigado, mas isso me fará ter que varrer todo código atrás de end() nos combos. Sempre usei end() para encerrar os combos desde o FiveWin 1.9 Karinha, uso o Workshop para criar os diálogos e ele cria automaticamente o CBS_DROPDOWNLIST , mas tem funcionado perfeitamente. Eu antes acessava o fórum do virtualobject mas esse acabou. Não tenho o endereço do fivewinbrasil. Manda ele. []'s Rogerio
combobox não encerra
[quote="rogerio":2fue2es3]Ronaldo Hide() funciona, obrigado, mas isso me fará ter que varrer todo código atrás de end() nos combos. Sempre usei end() para encerrar os combos desde o FiveWin 1.9 Karinha, uso o Workshop para criar os diálogos e ele cria automaticamente o CBS_DROPDOWNLIST , mas tem funcionado perfeitamente. Eu antes acessava o fórum do virtualobject mas esse acabou. Não tenho o endereço do fivewinbrasil. Manda ele. []'s Rogerio[/quote:2fue2es3] Rogerio, Mude Nas Propriedades do combo, Para DROPDOWN. Fivewin Brasil. <!-- m --><a class="postlink" href="http://www.fivewin.com.br">http://www.fivewin.com.br</a><!-- m --> Abraços.
combobox não encerra
João Mudei e continuou na mesma. Faça o seguinte teste: Na pasta Samples do FWH tem COMBOS.PRG Altere a última linha da função Main para ACTIVATE DIALOG oDlg CENTERED ON INIT oCbx2:end() você verá que o controle permanecerá ativo. []'s Rogerio
combobox não encerra
[quote="rogerio":1wgay6er]João Mudei e continuou na mesma. Faça o seguinte teste: Na pasta Samples do FWH tem COMBOS.PRG Altere a última linha da função Main para ACTIVATE DIALOG oDlg CENTERED ON INIT oCbx2:end() você verá que o controle permanecerá ativo. []'s Rogerio[/quote:1wgay6er] Rogerio meu querido, Porque no ON INIT, Porque queres fechar o COMBO, ao ENTRAR no DIALOGO?? O Correto, é VALID(), Fechas o COMBO, ao sair.
combobox não encerra
João porque um mesmo diálogo, é utilizado em inúmeras funções. Então em determinadas não uso certos controles, como get's, say's, combos. Então ao iniciar o diálogo, eu encerro o que não vou usar na função. Isso simplifica pacas o código. No caso de relatórios repetitivos, um mesmo diálogo serve para dezenas. P. Ex. um relatório tem que haver seleção de Fornecedores e Vendedores, então existem dois combos. Em outro relatório somente seleção de Vendedor. Então utilizo somente um combo e o outro é encerrado na carga do diálogo. []'s Rogerio
combobox não encerra
[quote="rogerio":1zle4o7z]João porque um mesmo diálogo, é utilizado em inúmeras funções. Então em determinadas não uso certos controles, como get's, say's, combos. Então ao iniciar o diálogo, eu encerro o que não vou usar na função. Isso simplifica pacas o código. No caso de relatórios repetitivos, um mesmo diálogo serve para dezenas. P. Ex. um relatório tem que haver seleção de Fornecedores e Vendedores, então existem dois combos. Em outro relatório somente seleção de Vendedor. Então utilizo somente um combo e o outro é encerrado na carga do diálogo. []'s Rogerio[/quote:1zle4o7z] ENTENDI ROGERIO, MAS NESTE CASO, NAO TEM COMO VOCE FINALIZAR O COMBO COM O END(), JÁ QUE VOCE ESTA ATIVANDO O DIALOGO, O QUE VOCE DEVE FAZER, EM MINHA MODESTA OPINIAO, E ESCONDER O COMBO, E APRENSENTA-LO QUANDO O MESMO FOR NECESSARIO. ESCONDER: OCBX:HIDE() MOSTRAR: OCBX:SHOW() Ou voce tambem pode ter quantos COMBOS sejam necessarios no mesmo lugar, usando apenas IDS diferentes e ESCONDE quem nao quer e MOSTRA quem voce quer em tempo real. Abraços.
combobox não encerra
OK, João o hide() funciona. Porém como sempre foi utilizado end(), desde o FW1.9 em TODOS os prg's de TODOS os sistemas, que dará várias centenas de prg's diferentes, terei que fazer a mudança de end() para hide() isso somente nos combos, pois os demais controles continuam sendo encerrados com end(). Isso aconteceu somente agora na atualização para o FWH 8.02. Se o Antonio Linares estiver lendo esta discussão talvez ele saiba porque o end() deixou de ser utilizado para encerrar combos. Eu simplesmente queria evitar um trabalho imenso ao substituir os end() por hide().. []'s Rogerio
combobox não encerra
[quote="rogerio":36dh98mk]OK, João o hide() funciona. Porém como sempre foi utilizado end(), desde o FW1.9 em TODOS os prg's de TODOS os sistemas, que dará várias centenas de prg's diferentes, terei que fazer a mudança de end() para hide() isso somente nos combos, pois os demais controles continuam sendo encerrados com end(). Isso aconteceu somente agora na atualização para o FWH 8.02. Se o Antonio Linares estiver lendo esta discussão talvez ele saiba porque o end() deixou de ser utilizado para encerrar combos. Eu simplesmente queria evitar um trabalho imenso ao substituir os end() por hide().. []'s Rogerio[/quote:36dh98mk] ROGERIO, EU USO A VERSAO 2.7, E TAMBÉM NÃO FUNCIONA O END(), SOMENTE O HIDE()/SHOW(). Abraços.
combobox não encerra
fiz alguns teste e consegui desta forma: ON INIT( oCbx2:End(.t.), oCbx2:destroy())
combobox não encerra
Valeu Ronaldo vou tentar assim também. Eu tive que voltar à versão anterior do FWH pois nesta última os COMBOBOX além desse problema na finalização, também estão se comportando diferentemente na inicialização. Quando um diálogo é carregado com combobox sem conteúdo, isto é, ITEMS = uma matriz vazia, ele gera este erro: Descricao do erro: Erro: BASE/1132 Bound error: array access Args: [ 1] = A { ... } [ 2] = N 1 Lista Cham. =========== Chamada de: COMBOBOX.PRG => TCOMBOBOX:KEYCHAR(0) Chamada de: => TWINDOW:HANDLEEVENT(0) Chamada de: CONTROL.PRG => TCONTROL:HANDLEEVENT(0) Chamada de: COMBOBOX.PRG => TCOMBOBOX:HANDLEEVENT(0) Chamada de: WINDOW.PRG => _FWH(0) Chamada de: => DIALOGBOX(0) Chamada de: DIALOG.PRG => TDIALOG:ACTIVATE(0) Em vários diálogos, o conteúdo dos cobobox são carregados somente após o usuário escolher alguma coisa, p. ex., selecionar um Fornecedor. Então inicializo o combo sem conteúdo e depois que o usuário fizer uma escolha os combos respectivos são carregados com conteúdo. []'s Rogerio
combobox não encerra
Bom dia Rogério, Atualizei minha versão do FHW e também ocorreu um problema no combobox, que seria o seguinte: o retorno da função deixou de ser o numero do indice e sim o valor do indice; pra não retornar a versão, o que eu fiz foi o seguinte: compilei junto com meu sistema o prg da classe, combobox.prg da versão em que o funcionamento me retornava o indice; o que eu recomendo a voce, compile o combobox.prg da versão que funciona corretamente junto com seu sistema, espero que resolva. []´s
combobox não encerra
Luiz eu já tentei fazer isso, compilar junto o prg da versão anterior, mas o programa assume o que estiver na lib do fivewin. Acho que tem relação com este post: <!-- m --><a class="postlink" href="http://fivetechsoft.com/forums/viewtopic.php?t=10138">http://fivetechsoft.com/forums/viewtopic.php?t=10138</a><!-- m --> []'s Rogerio
combobox não encerra
Rogerio, Prueba a añadir este método a la clase TComboBox y asi no tienes que modificar tu código: METHOD End() INLINE ::Hide(), Super:End()
combobox não encerra
Ok, Antonio funcionou, obrigado.
combobox of field inside Txbrowse
How to use this program to field array instead of fixed array ? [code:2j4jcwp6] #INCLUDE "FIVEWIN&#46;CH" procedure main&#40;&#41; LOCAL oWnd, oBrw, aDatos //MsgInfo&#40; "Hola Mundo" &#41; DEFINE WINDOW oWnd *aDatos &#58;= &#123; &#123; "uno ", "dos ", "tres ", "cuatro", "cinco " &#125;,; * &#123; "Seis ", "Siete ", "Ocho ", "Nueve ", "Diez " &#125; &#125; aDatos &#58;=creatarray&#40;&#41; WITH OBJECT &#40; oBrw &#58;= TXBrowse&#40;&#41;&#58;New&#40; oWnd &#41; &#41; &#58;SetArray&#40; aDatos &#41; WITH OBJECT &#58;aCols&#91;01&#93; &#58;cHeader &#58;= "Col1" &#58;nEditType &#58;= 01 &#58;bOnPostEdit &#58;= &#123; |oCol| aDatos&#91; oBrw&#58;nArrayAt &#93;&#91;01&#93; &#58;= oCol&#58;oEditGet&#58;cText &#125; END WITH OBJECT &#58;aCols&#91;02&#93; &#58;cHeader &#58;= "Col2" &#58;nEditType &#58;= 02 &#58;aEditListTxt &#58;= aDatos &#58;aEditListBound &#58;= &#58;aEditListTxt &#58;bOnPostEdit &#58;= &#123; |oCol,cOption| aDatos&#91; oBrw&#58;nArrayAt &#93;&#91;02&#93; &#58;= cOption &#125; END WITH OBJECT &#58;aCols&#91;03&#93; &#58;cHeader &#58;= "Col3" &#58;nEditType &#58;= 03 &#58;bOnPostEdit &#58;= &#123; || "" &#125; &#58;bEditBlock &#58;= &#123; || MsgInfo&#40; "Hola" &#41; &#125; END WITH OBJECT &#58;aCols&#91;04&#93; &#58;cHeader &#58;= "Col4" &#58;nEditType &#58;= 04 &#58;aEditListTxt &#58;= aDatos &#58;aEditListBound &#58;= &#58;aEditListTxt &#58;bOnPostEdit &#58;= &#123; |oCol,cOption| aDatos&#91; oBrw&#58;nArrayAt &#93;&#91;04&#93; &#58;= IF&#40; Len&#40; Alltrim&#40; cOption &#41; &#41; > 0, cOption, oCol&#58;oEditGet&#58;cText &#41; &#125; END WITH OBJECT &#58;aCols&#91;05&#93; &#58;cHeader &#58;= "Col5" &#58;nEditType &#58;= 05 &#58;bOnPostEdit &#58;= &#123; |oCol| aDatos&#91; oBrw&#58;nArrayAt &#93;&#91;05&#93; &#58;= oCol&#58;oEditGet&#58;cText &#125; &#58;bEditBlock &#58;= &#123; || MsgInfo&#40; "Hola" &#41; &#125; END &#58;CreateFromCode&#40;&#41; END oWnd&#58;oClient &#58;= oBrw Activate Window oWnd * TWINDOW&#40;&#41;&#58;ACTIVATE&#40; oWnd &#41; function creatarray&#40;&#41; local aData &#58;= &#123;&#125;,oDlg use mach mach->&#40;dbGotop&#40;&#41;&#41; do while !mach->&#40;eof&#40;&#41;&#41; aadd&#40; aData , mach->mc_serial &#41; mach->&#40;dbSkip&#40;&#41;&#41; enddo /* USE THIS ARRAY BY LISTBOX CLASS, you will get the names of mach from DBF */ return &#40;aData&#41; [/code:2j4jcwp6]
combobox of field inside Txbrowse
obrow := TXBrowse():New( odlg ) for i:=1 to len(array1) oCol := obrow:addCol() addcol(ocol,i) next return function addcol(ocol,i) oCol:cHeader :='aaa' oCol:bStrData := { ||array1[i]} ocol:beditvalue:={||array[i]} ocol:nedittype:= 1 oCol:bOnPostEdit := {|o, v, n| if( n != VK_ESCAPE .... } return Shuming Wang
combobox problemas con muchos datos es xp
si alguien me puede ayudar tengo un sistema que funciona muy bien en w98 pero cuando lo paso a wxp los combobox se ponen lentos y no puedo manejar su tamaño... desde ya muchas gracias
combobox seleccionar mas de un item
Estimados Necesito implementar en un combobox que se seleccione mas de un item es posible? de lo contrario algun ejemplo de como implementar?
combobox with Vscroll
Dear All, How can I define vscroll in combobox? Regards, Dutch
combobox with Vscroll
Dutch, What do you mean ? Please explain it, thanks
combobox with Vscroll
Dear Antonio, When I use combobox and number of array have more than number of row in combobox. I have to use arrow key to move the highlight down to the items that doesn't display. Thanks, Dutch
combobox with Vscroll
Dutch, If you are using it from resources please add this style to it: WS_VSCROLL If you are creating it from source code using @ ..., ... then you may need to modify the FW class and add that style also.
combobox with Vscroll
Thanks, I got it. Dutch
combobox with different colored items
I need a combobox with different colored items. At the moment I use bitmaps to show the color. But depending on the font this could become bad looking. Has someone an idea. Best regards, Otto [img:30jyoxp0]http&#58;//www&#46;atzwanger-software&#46;com/fw/combocolor&#46;jpg[/img:30jyoxp0] [code=fw:30jyoxp0]<div class="fw" id="{CB}" style="font-family: monospace;"> &nbsp;oCbxFixBuchung := TComboBox<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #0000ff;">ReDefine</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">2050</span>, <span style="color: #000000;">&#123;</span> | u | <span style="color: #00C800;">If</span><span style="color: #000000;">&#40;</span> PCount<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>==<span style="color: #000000;">0</span>, cItemFixBuchung, cItemFixBuchung:= u <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span>, aCOMBO,,,;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span>|| &nbsp;<span style="color: #000000;">&#40;</span> nOption := cbxSaBu<span style="color: #000000;">&#40;</span>oCbxFixBuchung:<span style="color: #000000;">nAt</span><span style="color: #000000;">&#41;</span> ,.T.<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#125;</span>,<span style="color: #000000;">&#123;</span>|Self|<span style="color: #000000;">&#40;</span> &nbsp;nOption := cbxSaBu<span style="color: #000000;">&#40;</span>oCbxFixBuchung:<span style="color: #000000;">nAt</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><span style="color: #000000;">&#125;</span>,,,, .F.,, &nbsp;<span style="color: #000000;">&#123;</span> <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"1.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"2.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"3.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"4.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"5.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"10.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"12.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"13.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"14.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"15.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"16.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"17.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"18.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span>Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"19.bmp"</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">&#40;</span> Setup<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Daten</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> + <span style="color: #ff0000;">"bmpsNet<span style="color: #000000;">\b</span>ooking"</span>+<span style="color: #ff0000;">"20.bmp"</span><span style="color: #000000;">&#41;</span> &nbsp;<span style="color: #000000;">&#125;</span>,,,, <span style="color: #000000;">&#41;</span><br />&nbsp;</div>[/code:30jyoxp0]
combobox with different colored items
Otto, I would be concerned about using colors like this. Many people have colorblindness and they will not see what you see. There is a website where you can run a simulation of different types of colorblindness. You just upload your graphic and the site converts it. Try it. <!-- m --><a class="postlink" href="http://aspnetresources.com/tools/colorBlindness">http://aspnetresources.com/tools/colorBlindness</a><!-- m --> Regards, James
combobox y el nAt
hola. [code=fw:2kopslho]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">COMBOBOX</span> ::<span style="color: #000000;">oGets</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">vGets</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">100</span> <span style="color: #0000ff;">OF</span> oDlg ;                 <span style="color: #B900B9;">// sucursal</span><br />   <span style="color: #0000ff;">ITEMS</span> ::<span style="color: #000000;">aSucursales</span></div>[/code:2kopslho] Consulta, al iniciar el modulo quiero que ::oGets[1] tome el primer valor que exista en ::aSucursales, he intentado hacer esto: [code=fw:2kopslho]<div class="fw" id="{CB}" style="font-family: monospace;">::<span style="color: #000000;">ogets</span><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">nAt</span>:= <span style="color: #000000;">1</span></div>[/code:2kopslho] pero no me da. Como seria?
combobox y el nAt
A mi me funciona de la siguiente manera: [code=fw:1ue3sq94]<div class="fw" id="{CB}" style="font-family: monospace;"><br />::<span style="color: #000000;">vGets</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> := <span style="color: #000000;">1</span><br />&nbsp;</div>[/code:1ue3sq94]
combobox y lostfocus
Hola. No hay manera, si en un dialogo hay un combobox y un folder, no hay manera de que salte al folder, ya probe utilziando el jump: [code=fw:1r1aa754]<div class="fw" id="{CB}" style="font-family: monospace;">oCombobox<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">ojump</span> = oGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#93;</span><br />&nbsp;</div>[/code:1r1aa754] ya probe poniendolo en el VALID del Combobox y nada... Que esta funcionando mal? gracias.
combobox y lostfocus
Simples, [code=fw:223v2rwu]<div class="fw" id="{CB}" style="font-family: monospace;"><br />&nbsp; &nbsp; <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">COMBOBOX</span> oCombo <span style="color: #0000ff;">VAR</span> XESTCIVIL <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@K!"</span> &nbsp; &nbsp; ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ITEMS</span> cEstCivil &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ID</span> <span style="color: #000000;">31</span> <span style="color: #0000ff;">OF</span> oFld:<span style="color: #000000;">aDialogs</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">UPDATE</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;COLORS CLR_HRED, CLR_HCYAN &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">VALID</span> &nbsp; <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> GetASyncKey<span style="color: #000000;">&#40;</span> VK_RETURN <span style="color: #000000;">&#41;</span> &nbsp; &nbsp; .OR. &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;GetASyncKey<span style="color: #000000;">&#40;</span> VK_DOWN &nbsp; <span style="color: #000000;">&#41;</span>, &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#40;</span> oCombo:<span style="color: #000000;">oJump</span> := oCbxSit, &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; xFocus<span style="color: #000000;">&#40;</span> oCbxSit <span style="color: #000000;">&#41;</span>, .T. <span style="color: #000000;">&#41;</span>, .T. <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp; oCombo:<span style="color: #000000;">cToolTip</span> := <span style="color: #ff0000;">"<Click-Me> Para Selecionar o Estado Civil do Cliente"</span><br /><br />&nbsp; &nbsp; <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">COMBOBOX</span> oCbxSit <span style="color: #0000ff;">VAR</span> XATIVO <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@K!"</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ITEMS</span> cSituacao &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ID</span> <span style="color: #000000;">32</span> <span style="color: #0000ff;">OF</span> oFld:<span style="color: #000000;">aDialogs</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">UPDATE</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;COLORS CLR_HRED, CLR_HCYAN &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">VALID</span> <span style="color: #00C800;">IF</span><span style="color: #000000;">&#40;</span> GetASyncKey<span style="color: #000000;">&#40;</span> VK_RETURN <span style="color: #000000;">&#41;</span> &nbsp; &nbsp; .OR. &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;GetASyncKey<span style="color: #000000;">&#40;</span> VK_DOWN &nbsp; <span style="color: #000000;">&#41;</span>, &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#40;</span> oCbxSit:<span style="color: #000000;">oJump</span> := aGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">070</span><span style="color: #000000;">&#93;</span>, &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;oFld:<span style="color: #000000;">SetOption</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#41;</span>, oFld:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;oFld:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, xFocus<span style="color: #000000;">&#40;</span> aGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">70</span><span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#41;</span>, .T. <span style="color: #000000;">&#41;</span>, .T. <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp; oCbxSit:<span style="color: #000000;">cToolTip</span> := <span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"<Click-Me> Para Selecionar"</span> <span style="color: #000000;">&#41;</span><br />&nbsp;</div>[/code:223v2rwu] 
combobox y lostfocus
Hola. Ya probe de esa manera y no me funciona.
combobox y lostfocus
Aca funciona perfecto: [code=fw:3ajuwdd1]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">FUNCTION</span> xFocus<span style="color: #000000;">&#40;</span> oObj <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;xSetFocus<span style="color: #000000;">&#40;</span> oObj <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;xSetFocus<span style="color: #000000;">&#40;</span> oObj <span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">RETURN</span><span style="color: #000000;">&#40;</span> .T. <span style="color: #000000;">&#41;</span><br /><span style="color: #B900B9;">//-------------------------------------------------------------------------//</span><br /><span style="color: #00C800;">FUNCTION</span> xSetFocus<span style="color: #000000;">&#40;</span> oObj <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; <span style="color: #00C800;">LOCAL</span> _oWnd := oObj:<span style="color: #000000;">oWnd</span>, _oTempo := <span style="color: #ff0000;">""</span><br />&nbsp; &nbsp; <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">Timer</span> _oTempo <span style="color: #0000ff;">Interval</span> <span style="color: #000000;">10</span> <span style="color: #0000ff;">of</span> _oWnd ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">Action</span> <span style="color: #000000;">&#40;</span> oObj:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, _oTempo:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">Timer</span> _oTempo<br /><span style="color: #00C800;">RETURN</span><span style="color: #000000;">&#40;</span> .T. <span style="color: #000000;">&#41;</span><br />&nbsp;</div>[/code:3ajuwdd1] 
combobox y lostfocus
verifica que el control en el rc tenfo la propiedad tabstop en true, sucede con resedit que por defecto la propiedad tabstop de los combobox y radoitems enta false [img:v07it1eg]https&#58;//i&#46;imgur&#46;com/tbE8Xv9&#46;png[/img:v07it1eg]
combobox y lostfocus
hola. Lo tengo en tabstop al combobox PERO el folder no, puse en TRUE/YES al folder y ahora si toma el foco. gracias.
combobox y lostfocus
Sip, se me ha pasado eso tambiem, que el systab32 debe tener la propiedad tabstop en true tambien. <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> que bueno que ya has resuelto. salu2
combobox y tecla Escape
Tengo un dialogo, con varios combobox y Get. El dialogo se activa con la clausula VALID: ACTIVATE DIALOG oDlg VALID (!lGrabar) Cuando estoy en el segundo COMBO si puso la tecla Escape no hace nada (la variable lGranar := .f.). En cambio si despliego el combobox si reacciona. Esta la claúsula para que salte: oDlg:bKeyDown:={|nK| IIF ( nK != VK_ESCAPE, , ; ( NOSALIR(oDlg, lGrabar, oDbf), ; lGrabar:=.f., oDlg:End() ) ) } Cuando le quito la clausula VALID del ACTIVATE funciona tambien. ¿Hay alguna manera de que responda a ESCAPE el combo, sin estar desplegado? Un saludo y gracias Manuel
combobox y tecla Escape
Manuel, Puedes probar samples\combos.prg y confirmarnos si te ocurre igual ? Aqui funciona bien con el build de Marzo.
combobox y tecla Escape
Antonio, te acompaño el código de combos.prg con algunas modificaciones señaladas con negrita. En el ejemplo, si cambio el combo segundo, y pulso <Escape>, debe salir el mensaje "¿Desea guardar los cambios?". Pues igual que en mi aplicación, si modifico y despliego el combo segundo, es correcto, pero si no está desplegado el combo segundo (y lo he modificado previamente) el programa no responde a la tecla <Escape>, se queda como muerto. Si le quito el Valid del Activate, funciona.- Pero yo necesito el valid porque no quiero que salga del dialogo hasta contestar si "Quiero modificar o no". Con los Get funciona perfectamente, pero al meterle un Combo, falla. #include "FiveWin.ch" #include "Combos.ch" //----------------------------------------------------------------------------// function Main() local oDlg, oSay local oCbx1, oCbx2, oCbx3 local cItem1, cItem2 := "One", cItem3, cItem4 := "None" [b:kod5ipje]local lGrabar := .f. [/b:kod5ipje] SET _3DLOOK ON DEFINE DIALOG oDlg RESOURCE "Combos" REDEFINE COMBOBOX oCbx1 VAR cItem1 ITEMS { "One", "Two", "Three" } ; ID ID_SIMPLE OF oDlg ; ON CHANGE ( cItem4 := cItem1, oSay:Refresh() ) ; VALID ( cItem4 := cItem1, oSay:Refresh(), .t. ) REDEFINE COMBOBOX oCbx2 VAR cItem2 ITEMS { "One", "Two", "Three" } ; ID ID_DROPDOWN OF oDlg ; STYLE CBS_DROPDOWN ; ON CHANGE ( cItem4 := cItem2, [b:kod5ipje]lGrabar := .t.[/b:kod5ipje], oSay:Refresh() ) ; VALID ( If( ! oCbx2:Find( oCbx2:oGet:GetText() ),; oCbx2:Add( oCbx2:oGet:GetText() ),), .t. ) REDEFINE COMBOBOX oCbx3 VAR cItem3 ITEMS { "One", "Two", "Three" } ; ID ID_DROPDOWNLIST OF oDlg ; ON CHANGE ( cItem4 := cItem3, oSay:Refresh() ) ; VALID ( cItem4 := cItem3, oSay:Refresh(), .t. ) REDEFINE SAY oSay PROMPT cItem4 ID ID_SELECTION OF oDlg COLOR "R+/W" [b:kod5ipje] oDlg:bKeyDown:={|nK| IIF ( nK != VK_ESCAPE, , ; ( alert ("¿Desea guardar los cambios?"), ; lGrabar:=.f., oDlg:End() ) ) }[/b:kod5ipje] // ACTIVATE DIALOG oDlg CENTERED ACTIVATE DIALOG oDlg [b:kod5ipje]VALID(!lGrabar)[/b:kod5ipje] ; ON INIT (oDlg:lHelpIcon:=.f., .F.) return nil //----------------------------------------------------------------------------// procedure AppSys return //----------------------------------------------------------------------------// Como siempre, muchas gracias por tu ayuda. Un saludo desde Málaga Manuel
combobox y tecla Escape
Manuel, Gracias por el ejemplo. La pregunta que le haces al usuario en bKeyDown, debes hacérsela en el VALID: [code:2l48uu6w] ACTIVATE DIALOG oDlg ; VALID If&#40; MsgYesNo&#40; "¿Quiere guardar los cambios?" &#41;, &#40; &#46;&#46;&#46;, &#46;t&#46;&#41;, &#46;f&#46; &#41; [/code:2l48uu6w]
combobox y tecla Escape
Antonio, Ha funcionado perfectamente. Muchisimas gracias. Un saludo desde Málaga Manuel
combometro bug
Good morning There is a bug in calculating the coordinates of the combometro. A big space before the elements is shown and it is not always the same spacing depending on what element you selected. I join an image to show the problem. Richard [img:2olcuefl]http&#58;//www&#46;cbati&#46;com/combometro&#46;png[/img:2olcuefl]
combometro bug
[quote:1i3bagju]There is a bug in calculating the coordinates of the combometro. A big space before the elements is shown and it is not always the same spacing depending on what element you selected.[/quote:1i3bagju] Actually this is not a bug. This is how we designed when we first made the class long time back. Well you can say we ought to have designed it differently. We welcome any suggestions.
combometro bug
Mr Rao Personnally i have never seen a combobox starting in the middle of a rectangle or any other random place If it is a design issue..... I would suggest we have a standard behaviour (starting at the beginning) Thank you Richard
combometro bug
I agree the design needs to be modified somewhat. But here the selected item appears just at the place of the control. We shall soon have a relook into this to match windows 8 behavior exactly.
combometro bug
Thank you Richard
combometro bug
VIDEO here <!-- m --><a class="postlink" href="http://www.atzwanger-software.com/fw/cm.wmv">http://www.atzwanger-software.com/fw/cm.wmv</a><!-- m --> Shows the blank lines at the top or at the end of ComboMetroBox. Hallo Antonio, I put a small repetition. COMBOMETRO is quite urgent for the whole Metro Style like programming capabilities of FIVEWIN. Metro Style like programming capabilities of FIVEWIN is the main advantage Fivewin has over the other programming languages. There are afaik no other languages offering this possibility. The next years (5-7) will not have much real Metro Style programs ready. First missing hardware – these only run on W8 system Second you cannot transform a whole program in short time. So a step by step transformation would be best. Metro Style is a design concept which you have to get used to. Please Antonio would you be so kind to fix these little problems. Best regards, Otto
combometro bug
Otto, Richard, There is a quick fix thats seems to work <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> In combom.prg line 411: nTopRows := 0 // instead of nTopRows -= n Please try it on your apps and let me know your results, thanks
combometro bug
Antonio The change is ok, the combo shows now from the beginning Thank you Richard
combometro bug
Hello Antonio, this fix does not resolve the problem. With this fix the comboBox has no blank rows at top still on bottom but the item which is selected is somewhere. Not over the “getfield”. This version still has the problem with the color of the selected row. In the copy I work with I changed following line. ::bClrSelFocus := { || { CLR_WHITE, CLR_GREEN } } //otto Best regards, Otto
combometro bug
Otto, Do you mean to have the same standard Windows (desktop) combobox behavior ?
combometro bug
Hello Antonio, if you use this version on a white window you do not see anything. Best regards, Otto
combometro with images
ho wI c an use combometro with images @ 9,385 ; COMBOMETRO oNum1 VAR nNumFrom ; PROMPTS ArrTranspose( aElementi )[5 ] ; OF oGr ; SIZE 400, 40 ; PIXEL ; COLOR CLR_WHITE, RGB( 0x33, 0x66, 0xCC ) for n=1 to len(aElementi) oNum1:aItems[n]:cDataType := 'F' next
combox control convert to tab control
on a dialog I have a combobox [code:24szdr5w] REDEFINE COMBOBOX oCbx VAR cVar ITEMS aIdx ID 210 OF oDlg; ON CHANGE Sel_Index&#40;oCbx&#41; &#46;&#46;&#46; STAT FUNC Sel_Index&#40;oCbx&#41; &#40;oDCli&#41;->&#40;OrdSetFocus&#40;oCbx&#58;nAt&#41;&#41; oBCli&#58;Refresh&#40;&#41; oBCli&#58;SetFocus&#40;&#41; oBCli&#58;aHeaders&#91;5&#93;&#58;=IF&#40;oCbx&#58;nAt=5,"Vendita Netta","Saldo Attuale"&#41; RETURN &#40;NIL&#41; [/code:24szdr5w] I want insert on the botton of dialog a Tab with the same operation but when i try it make error i try with [code:24szdr5w]@ &#40; oDlg&#58;nHeight / 2 &#41; - 11, nBrwSplit+2 TABS oCbx ; SIZE oWnd&#58;nWidth&#40;&#41; - 80, 12 ; PIXEL ; OF oDlg ; ITEMS aIdx ; COLOR CLR_BLACK, GetSysColor&#40;15&#41; - rgb&#40; 30, 30, 30 &#41;; // 13362404 ; action Sel_Index&#40;oCbx[/code:24szdr5w] How can I make it to click on each tabs and index the listbox and focus on the order i selected ? Thanks in advance
combox control convert to tab control
Silvio, What error do you get ?
combox control convert to tab control
when I insert this code [code:1lq2nh6t] @ &#40; oDlg&#58;nHeight / 2 &#41; - 11, nBrwSplit+2 TABS oCbx ; SIZE oWnd&#58;nWidth&#40;&#41; - 80, 12 ; PIXEL ; OF oDlg ; ITEMS aIdx ; COLOR CLR_BLACK, GetSysColor&#40;15&#41; - rgb&#40; 30, 30, 30 &#41;; // 13362404 ; action Sel_Index&#40;oCbx&#41;[/code:1lq2nh6t] make this error Application =========== Path and name: C:\Work\prg\maga32\maga32.Exe (32 bits) Size: 797,696 bytes Time from start: 0 hours 0 mins 1 secs Error occurred at: 06/12/2005, 01:05:31 Error description: Error BASE/1126 Argument error: STRTRAN Args: [ 1] = A { ... } [ 2] = C & [ 3] = C Stack Calls =========== Called from STRTRAN(0) Called from TTABS:DEFAULT(305) Called from TTABS:NEW(122) Called from MAW110(191) Called from (b)PERFORM(237) Called from PERFORM(238) Called from (b)MAWIND(159) Called from TBTNBMP:CLICK(0) Called from TBTNBMP:LBUTTONUP(0) Called from TWINDOW:HANDLEEVENT(0) Called from TBTNBMP:HANDLEEVENT(0) Called from _FWH(0) Called from WINRUN(0) Called from TMDIFRAME:ACTIVATE(0) Called from MAWIND(25)
come verificare se JRE (java) e' installato
Salve, un amico mi ha dato una utility esterna scritta in Java x la gestione delle immagini, mi occorrerebbe sapere (prima di lanciare il .jar del java) se java e' stato installato sul PC. Sapete come posso fare ? Grazie
comenzar a programar
Hola, tengo experiencia en clipper, quisiera saber que necesito para comenzar a programar en POcket pc con FWPPC.Tambien desearía saber si hay documentación.Gracias
comenzar a programar
Gabriel,Además de conocer Clipper, te ayuda si tienes experiencia en programación en Windows (usando FiveWin, ó el API de Windows directamente).La documentación es basicamente la misma que la de FiveWin. De hecho si sabes programar en FiveWin entonces ya sabes programar con FWPPC.Aqui tienes un curso de programación con FiveWin que es muy recomendable que revises:<!-- w --><a class="postlink" href="http://www.fivetechsoft.com/files/curso.zip">www.fivetechsoft.com/files/curso.zip</a><!-- w -->Con FWPPC te entregamos todas las herramientas adicionales que necesitas para trabajar con él. Tienes más información en: <!-- m --><a class="postlink" href="http://www.fivetechsoft.com/spanish/fwppc.html">http://www.fivetechsoft.com/spanish/fwppc.html</a><!-- m -->
comenzar a programar
Gracias, por tu ayuda.La programación con fwppc para pocketpc te permite enviar y recibir archivos por medio de internet.gracias
comenzar a programar
Si. Puedes enviar ficheros usando FTP, ó directamente usando sockets.
comma instead dot
why I have comma instead dot in numeric keyboard (right part keyboard) I used polish chars: REQUEST HB_LANG_PL852 REQUEST HB_CODEPAGE_PL852 best regards kajot
comma instead dot
Kajot, IMO thats a Windows region (keyboard) settings. Does it work fine with other software ?
command-line arguments
Is there a function which returns the command-line arguments specified when the program was launched. text.exe ABC prg Local cTest :="" cTest:=command() Regards Otto
command-line arguments
This is a sample: [code:37ql823l]FUNCTION MAIN&#40; cPar1, cPar2, cPar3 &#41; LOCAL i ? cPar1, cPar2, cPar3 ? FOR i = 0 TO HB_ARGC&#40;&#41; ? HB_ARGV&#40; i &#41; NEXT ? RETURN NIL[/code:37ql823l] EMG
command-line arguments
[code:1tabwz8s] #include "FiveWin&#46;Ch" FUNCTION MAIN&#40;&#46;&#46;&#46;&#41; ************* LOCAL Arr &#58;= Hb_Aparams&#40;&#41; AEVAL&#40;Arr,&#123;|j|msginfo&#40;j&#41;&#125;&#41; RETURN [/code:1tabwz8s]
command-line arguments
Thank you. Otto
commctrl again
hi, in march build, in whatsnew, says commctrl.dll is not more needed, but in april build is need again, this is right?? thanks
commctrl again
Norberto, Do you have a sample that shows that it is required again ? thanks,
commctrl again
Antonio, i only see in whatsnew this, and confused me... april build * New: FWPPC, Class TDatePicker already implemented. Please review samples\TestDtp.prg. Please notice that lib\commctrl.lib has to be linked now. february build * Enhancement: FiveWin for CA-Clipper (16 bits) no longer needs COMMCTRL.DLL. If you plan to use ImageLists, then you should have it available, though the EXE will start normally even if it is not present.