topic
stringlengths
1
63
text
stringlengths
1
577k
drawline method
drawline method on richedit not run good I thinked to make this ACTION oRtf:DrawLine() [code=fw:1w9whzrr]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /><span style="color: #00C800;">Method</span> Drawline<span style="color: #000000;">&#40;</span> nTop, nLeft, nBottom, nRight, nColor, nWPen, nStyle <span style="color: #000000;">&#41;</span> <span style="color: #00C800;">CLASS</span> TRichEdit<br /><br /><span style="color: #00C800;">local</span> hPen, hOldPen<br /><span style="color: #00C800;">local</span> hdc &nbsp; &nbsp; := ::<span style="color: #000000;">GetDc</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">DEFAULT</span> nWPen &nbsp;:= <span style="color: #000000;">1</span><br /><span style="color: #00C800;">DEFAULT</span> nColor := <span style="color: #000000;">0</span><br /><span style="color: #00C800;">DEFAULT</span> nStyle := PS_SOLID<br /><br />&nbsp; &nbsp;<span style="color: #00C800;">DEFAULT</span> nTop &nbsp; &nbsp; &nbsp;:= ::<span style="color: #000000;">aOldPos</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">DEFAULT</span> nLeft &nbsp; &nbsp; := ::<span style="color: #000000;">aOldPos</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">DEFAULT</span> nBottom &nbsp; := ::<span style="color: #000000;">aPos</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">DEFAULT</span> nRight &nbsp; &nbsp;:= ::<span style="color: #000000;">aPos</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span><br /><br /><br /><br />hPen := CreatePen<span style="color: #000000;">&#40;</span> nStyle, nWPen, nColor <span style="color: #000000;">&#41;</span><br /><br />hOldPen := SelectObject<span style="color: #000000;">&#40;</span> hDC, hPen <span style="color: #000000;">&#41;</span><br />MoveTo<span style="color: #000000;">&#40;</span> hDC, nLeft, nTop <span style="color: #000000;">&#41;</span><br />LineTo<span style="color: #000000;">&#40;</span> hDC, nRight, nBottom <span style="color: #000000;">&#41;</span><br /><br />SelectObject<span style="color: #000000;">&#40;</span> hDC, hOldPen <span style="color: #000000;">&#41;</span><br /><br />DeleteObject<span style="color: #000000;">&#40;</span> hPen <span style="color: #000000;">&#41;</span><br /><br />&nbsp;::<span style="color: #000000;">ReleaseDc</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">return</span> <span style="color: #000000;">0</span><br />&nbsp;</div>[/code:1w9whzrr]
drawselect
on wbrowse there is draselect function in xbrowse wich func we can use ?
drawselect
oBrw:drawLine( .t. ) does what drawSelect() does for wbrowse
drawselect
thanks
drawtext() can do with 2 bytes wordmemoline() can't
Hi, Fivewin function drawtext() can do with 2 bytes word, but memoline() will split a 2 byte word ,like Chinese word. What function could split a cstring as drawtext() do ? Thanks ! Shuming Wang
driver myodbc in ADORDD
Salve a tutti, Sto usando ADORDD con FWH 10.1 , e mi sembra di capire che sono costreto ad usare la versione 3.51 di myodbc; c'è modo per usare la 5.1 per la connessione ? Grazie Saluti Walter Zafferami
drooling
[img:2ox6c8ds]https&#58;//i&#46;postimg&#46;cc/WzGNwsjQ/j&#46;jpg[/img:2ox6c8ds] What can I do to prevent the blue color from drooling beyond the border of the btnbmp button? :bClrGrad = { | lInvert | If( ! lInvert,; { { 1, RGB( 244, 244, 245 ), RGB( 244, 244, 245 ) } },; { { 1, RGB( 145, 201, 247 ), RGB( 145, 201, 247 ) } } ) }
drooling
Silvio Did you solve it? If yes, can you tell us how you did it? I ask this because I want to make sure before modifying the class.
drooling
No Sorry, I 'm waiting gurus message
drop file information
If i take a file ( I drop a file into a dialog with mouse ) how I can Know his informations : 1. name of file 2.size 3. last modify 4.type of file thanks
drop from the URL
Hello, I want to receive a drop from the URL in IE in a winforms control. I get no drag enter event. Does anyone know how to do this. Thanks in advance Otto
drop from the URL
Otto, This may help you: [quote:3qme4ckw] //-------------------------------------------------------------------------------------------------- FUNCTION URLDownLoad(cUrl, cSaveAs) //-------------------------------------------------------------------------------------------------- sysrefresh() if !URLDownloadToFile( 0, cUrl, cSaveAs, 0, 0 ) == 0 retu.f. endif retu.t. //-------------------------------------------------------------------------------------------------- DLL32 FUNCTION URLDownloadToFile(pCaller AS LONG,szURL AS STRING, szFileName AS STRING, dwReserved AS LONG, lpfnCB AS LONG) ; AS LONG PASCAL; FROM "URLDownloadToFileA"; LIB "urlmon.dll" [/quote:3qme4ckw]
drop from the URL
Thank you, Lukas. But how do I call this function. Best regards, Otto
drop from the URL
Otto, cUrl := "http://www.sistemasintegrales.es/ficheros/update.exe" cSaveAs := "c:\temp\update.exe" URLDownLoad(cUrl, cSaveAs)
drop from the URL
Hello Lukas, Thank you. But I need a possibility to drag from IE and to get the link in a WINForm. I post a screen shot to show you what I mean. Best regards, Otto [img:2u4rowgk]http&#58;//www&#46;atzwanger-software&#46;com/fw/drapIE&#46;jpg[/img:2u4rowgk]
drop from the URL
Otto, Simply use a RichEdit control instead of that multiline Get and you will automatically get it <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
drop to GET how ?
hi, i have some GET and enable "DROPFILES" [code=fw:3uvjpslv]<div class="fw" id="{CB}" style="font-family: monospace;">   <span style="color: #0000ff;">ON</span> DROPFILES DoDropFiles<span style="color: #000000;">&#40;</span> nRow, nCol, aFiles <span style="color: #000000;">&#41;</span></div>[/code:3uvjpslv] i try to found TGET and compare Position where i drop [code=fw:3uvjpslv]<div class="fw" id="{CB}" style="font-family: monospace;">PROCEDURE DoDropFiles<span style="color: #000000;">&#40;</span> nRow, nCol, aFiles <span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">LOCAL</span> ii, iMax, oObj, cVALTYPE<br /><span style="color: #00C800;">LOCAL</span> aCtrls   := oMain:<span style="color: #000000;">aControls</span><br /><br />   cVALTYPE := VALTYPE<span style="color: #000000;">&#40;</span>aFiles<span style="color: #000000;">&#41;</span><br />   FWLOG <span style="color: #ff0000;">"VALTYPE"</span>, cVALTYPE, aFiles<br /><br />   <span style="color: #00C800;">FOR</span> ii := <span style="color: #000000;">1</span> <span style="color: #0000ff;">TO</span> LEN<span style="color: #000000;">&#40;</span> aCtrls <span style="color: #000000;">&#41;</span><br />      oObj := aCtrls<span style="color: #000000;">&#91;</span> ii <span style="color: #000000;">&#93;</span><br /><br />      <span style="color: #00C800;">IF</span> VALTYPE<span style="color: #000000;">&#40;</span> oObj <span style="color: #000000;">&#41;</span> == <span style="color: #ff0000;">"O"</span><br />         <span style="color: #00C800;">DO</span> <span style="color: #00C800;">CASE</span><br />            <span style="color: #00C800;">CASE</span> oObj:<span style="color: #000000;">ClassName</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> == <span style="color: #ff0000;">"TGET"</span><br />            <span style="color: #00C800;">IF</span> oObj:<span style="color: #000000;">nTop</span> <= nRow .AND. nRow <= oObj:<span style="color: #000000;">nTop</span> + oObj:<span style="color: #000000;">nHeight</span><br />               <span style="color: #00C800;">IF</span> oObj:<span style="color: #000000;">nLeft</span> <= nCol .AND. nCol <= oObj:<span style="color: #000000;">nLeft</span> + oObj:<span style="color: #000000;">nWidth</span><br /><br />                  <span style="color: #B900B9;">// drop to GET</span><br />                  <span style="color: #00C800;">IF</span> cVALTYPE = <span style="color: #ff0000;">"A"</span><br />                     oObj:<span style="color: #000000;">cVarName</span> := aFiles<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span><br />                  <span style="color: #00C800;">ELSE</span><br />                     oObj:<span style="color: #000000;">cVarName</span> := aFiles<br />                  <span style="color: #00C800;">ENDIF</span><br />                  oObj:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />                  FWLOG oObj:<span style="color: #000000;">nTop</span>, nRow, oObj:<span style="color: #000000;">nTop</span> + oObj:<span style="color: #000000;">nHeight</span><br />                  FWLOG oObj:<span style="color: #000000;">nLeft</span>, nCol, oObj:<span style="color: #000000;">nLeft</span> + oObj:<span style="color: #000000;">nWidth</span><br /><br />                  EXIT<br />               <span style="color: #00C800;">ENDIF</span><br />            <span style="color: #00C800;">ENDIF</span><br />         <span style="color: #00C800;">ENDCASE</span><br />      <span style="color: #00C800;">ELSE</span><br />         FWLOG <span style="color: #ff0000;">"not Object"</span>, oObj<br />      <span style="color: #00C800;">ENDIF</span><br />   <span style="color: #00C800;">NEXT</span><br /><br /><span style="color: #00C800;">RETURN</span></div>[/code:3uvjpslv] Position seems right in Logfile but it does not appear in GET ... is ::cVarName right <!-- s:?: --><img src="{SMILIES_PATH}/icon_question.gif" alt=":?:" title="Question" /><!-- s:?: --> --- [code=fw:3uvjpslv]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">STATIC</span> oMain<br /><br />PROCEDURE MAIN<span style="color: #000000;">&#40;</span> cDbf1, cDbf2 <span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">LOCAL</span> oText_1<br /><span style="color: #00C800;">LOCAL</span> oText_2<br /><span style="color: #00C800;">LOCAL</span> oBtn_1<br /><span style="color: #00C800;">LOCAL</span> oBtn_2<br /><span style="color: #00C800;">LOCAL</span> oBtn_3<br /><span style="color: #00C800;">LOCAL</span> oBtn_4<br /><span style="color: #00C800;">LOCAL</span> cDBF_1 := <span style="color: #ff0000;">""</span><br /><span style="color: #00C800;">LOCAL</span> cDBF_2 := <span style="color: #ff0000;">""</span><br /><br />   <span style="color: #00C800;">IF</span> !EMPTY<span style="color: #000000;">&#40;</span> cDbf1 <span style="color: #000000;">&#41;</span><br />      cDBF_1 := cDbf1<br />   <span style="color: #00C800;">ENDIF</span><br />   <span style="color: #00C800;">IF</span> !EMPTY<span style="color: #000000;">&#40;</span> cDbf2 <span style="color: #000000;">&#41;</span><br />      cDBF_2 := cDbf2<br />   <span style="color: #00C800;">ENDIF</span><br /><br />   <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">WINDOW</span> oMain <span style="color: #0000ff;">FROM</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span> <span style="color: #0000ff;">TO</span> <span style="color: #000000;">600</span>, <span style="color: #000000;">800</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"FiveWin Sync DBF Demo "</span> + cVersion <span style="color: #0000ff;">ICON</span> <span style="color: #ff0000;">"A1MAIN"</span> NOMAXIMIZE NOMINIMIZE<br /><br />      @ <span style="color: #000000;">010</span>, <span style="color: #000000;">010</span> <span style="color: #0000ff;">BUTTON</span> oBtn_1 <span style="color: #0000ff;">PROMPT</span> FWString<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"Source DBF"</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span>, <span style="color: #000000;">30</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</span> cDBF_1 := cGetFile<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"DBF File(*.dbf)|*.dbf|"</span>, <span style="color: #ff0000;">"Select any dbf file"</span>,, CURDIR<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>, oText_1:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">OF</span> oMain<br />      @ <span style="color: #000000;">010</span>, <span style="color: #000000;">120</span> <span style="color: #0000ff;">GET</span> oText_1 <span style="color: #0000ff;">VAR</span> cDBF_1 <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">650</span>, <span style="color: #000000;">30</span> <span style="color: #0000ff;">PIXEL</span><br /><br />      @ <span style="color: #000000;">080</span>, <span style="color: #000000;">010</span> <span style="color: #0000ff;">BUTTON</span> oBtn_2 <span style="color: #0000ff;">PROMPT</span> FWString<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"Target DBF"</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">100</span>, <span style="color: #000000;">30</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</span> cDBF_2 := cGetFile<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"DBF File(*.dbf)|*.dbf|"</span>, <span style="color: #ff0000;">"Select any dbf file"</span>,, CURDIR<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>, oText_2:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">OF</span> oMain<br />      @ <span style="color: #000000;">080</span>, <span style="color: #000000;">120</span> <span style="color: #0000ff;">GET</span> oText_2 <span style="color: #0000ff;">VAR</span> cDBF_2 <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">650</span>, <span style="color: #000000;">30</span> <span style="color: #0000ff;">PIXEL</span><br /><br />   <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> oMain ;<br />      <span style="color: #0000ff;">ON</span> DROPFILES DoDropFiles<span style="color: #000000;">&#40;</span> nRow, nCol, aFiles <span style="color: #000000;">&#41;</span> ;<br />      <span style="color: #0000ff;">CENTER</span><br /><br /><span style="color: #00C800;">RETURN</span></div>[/code:3uvjpslv]
drop to GET how ?
Dear Jimmy, Please try it this way: [code=fw:2yk2a1io]<div class="fw" id="{CB}" style="font-family: monospace;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00C800;">IF</span> cVALTYPE = <span style="color: #ff0000;">"A"</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;oObj:<span style="color: #000000;">VarPut</span><span style="color: #000000;">&#40;</span> aFiles<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 />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00C800;">ELSE</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;oObj:<span style="color: #000000;">VarPut</span><span style="color: #000000;">&#40;</span> aFiles <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00C800;">ENDIF</span></div>[/code:2yk2a1io]
drop to GET how ?
Another alternative is to make the Get accept drop. Sample: [code=fw:2guvvsdm]<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 /><br />   <span style="color: #00C800;">local</span> oWnd, oGet, cVar := <span style="color: #ff0000;">"Drop here"</span><br /><br />   <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">WINDOW</span> oWnd<br /><br />   @ <span style="color: #000000;">40</span>,<span style="color: #000000;">20</span> <span style="color: #0000ff;">GET</span> oGet <span style="color: #0000ff;">VAR</span> cVar <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">400</span>,<span style="color: #000000;">20</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oWnd<br /><br />   oGet:<span style="color: #000000;">bDropFiles</span> := <span style="color: #000000;">&#123;</span> |r,c,aFiles| oGet:<span style="color: #000000;">cText</span> := aFiles<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#125;</span><br />   DragAcceptFiles<span style="color: #000000;">&#40;</span> oGet:<span style="color: #000000;">hWnd</span>, .t. <span style="color: #000000;">&#41;</span><br /><br />   @ <span style="color: #000000;">90</span>,<span style="color: #000000;">20</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #ff0000;">"CLOSE"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">60</span>,<span style="color: #000000;">40</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oWnd ;<br />      <span style="color: #0000ff;">ACTION</span> <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span> cVar <span style="color: #000000;">&#41;</span><br /><br />   <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> oWnd <span style="color: #0000ff;">CENTERED</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span></div>[/code:2guvvsdm] Now, drag a file and directly drop on the Get.
drop to GET how ?
Hello Nages Very nice example! Thank you. Your example works correctly, but only with Window, with Dialog or Window MDI Child it doesn't work. It is possible to work this option with Dialogs? Best regards. Carlos
drop to GET how ?
[code=fw:2g7tjdul]<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 /><br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> oDlg, oGet, cVar := <span style="color: #ff0000;">"Drop here"</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">500</span>,<span style="color: #000000;">300</span> <span style="color: #0000ff;">PIXEL</span> TRUEPIXEL<br /><br />&nbsp; &nbsp;@ <span style="color: #000000;">40</span>,<span style="color: #000000;">20</span> <span style="color: #0000ff;">GET</span> oGet <span style="color: #0000ff;">VAR</span> cVar <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">400</span>,<span style="color: #000000;">20</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlg<br /><br /><br />&nbsp; &nbsp;@ <span style="color: #000000;">90</span>,<span style="color: #000000;">20</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #ff0000;">"CHECK"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">60</span>,<span style="color: #000000;">40</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ACTION</span> <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span> cVar <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;oDlg:<span style="color: #000000;">bInit</span> &nbsp;:= <||<br />&nbsp; &nbsp; &nbsp; oGet:<span style="color: #000000;">bDropFiles</span> := <span style="color: #000000;">&#123;</span> |r,c,aFiles| oGet:<span style="color: #000000;">cText</span> := aFiles<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#125;</span><br />&nbsp; &nbsp; &nbsp; DragAcceptFiles<span style="color: #000000;">&#40;</span> oGet:<span style="color: #000000;">hWnd</span>, .t. <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br />&nbsp; &nbsp; &nbsp; ><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTERED</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br />&nbsp;</div>[/code:2g7tjdul]
drop to GET how ?
Excellent, it worked very well!! Thank you Nages. Best regards. Carlos.
dsay and sayref trasparent
Wherei can download dsay and sayref trasparent : i want use it on a dialog ...brush obrush...trasparent Regards
dsay and sayref trasparent
Silvio, I have sent some files to your private email, they may be helpful for you Stefan
dsay and sayref trasparent
thank but I have these files... I made a dialog : [code:3ushbuqk] FUNCTION Info&#40;&#41; local oDlg, aGet&#91;9&#93;, cPrompt, oTmr,obr local oMs10Under &#58;= TFont&#40;&#41;&#58;New&#40;"Ms Sans Serif",0,-12,,&#46;f&#46;,,,,,&#46;t&#46;&#41; DEFINE BRUSH oBr FILE "d48&#46;BMP" define dialog oDlg title 'Authors ' BRUSH oBr TRANSPARENT ; FROM 0, 0 TO 240, 330 PIXEL @ 00,08 BITMAP aGet&#91;1&#93; FILE 'ACERCADE2&#46;BMP' ; SIZE 34, 54 OF oDlg PIXEL NOBORDER TRANSPAREN @ 10,44 BITMAP aGet&#91;2&#93; FILE 'ACERCADE1&#46;BMP' ; SIZE 94, 20 OF oDlg PIXEL NOBORDER TRANSPAREN @ 32,10 SAYREF aGet&#91;4&#93; PROMPT "http&#58;//www&#46;" ; SIZE 142,10 PIXEL CENTERED OF oDlg ; HREF "http&#58;//www&#46;" ; FONT oMs10Under aGet&#91;4&#93;&#58;cTooltip &#58;= xxxxxxxxx @ 54,10 DYNAMIC SAY oSay ; PROMPT CRLF+CRLF+CRLF+; " This application is distribuited on "+CRLF+; "Creative Commons 2&#46;0 Licence "+CRLF+; "http&#58;//creativecommons&#46;org/licenses/by-nc-nd/"+CRLF+CRLF+; "This software is created with the cooperation with "+CRLF+"xxxxxxxx"+CRLF+; "Made in xharbour and fivewin"+CRLF+CRLF+CRLF+CRLF; SIZE 140, 46 PIXEL CENTERED ; VERTICAL SCROLL SPEED 40; WRAP activate dialog oDlg CENTERED oMs10Under&#58;End&#40;&#41; return nil [/code:3ushbuqk] it make dsay scroll in a white box WHY ?????? it is not trasparent !!!!!!!!!!!!!!!!!!!!! REGARDS,
dsay and sayref trasparent
Sorry, I don´t know. I´ve never use used the class TDSay. Compare the this class with the others working in transparent mode and look how the output is implemented. Stefan
dtPicker Muestre la Fecha Vacia
Amigo como hacer que dtPicker muestre la fecha vacia, siempre muestra la fecha actual. saludos
dtPicker Muestre la Fecha Vacia
Mira a ver si te sirve <!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=27644&p=154376&hilit=dtPicker#p154342">viewtopic.php?f=3&t=27644&p=154376&hilit=dtPicker#p154342</a><!-- l --> <!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=17972&hilit=dtpicker#p93894">viewtopic.php?f=3&t=17972&hilit=dtpicker#p93894</a><!-- l -->
dtpicker and empty date
I cannot get the control to start with an empty date. dBegDate := ctod('') REDEFINE DTPicker oBegDate VAR dBegDate ID 101 UPDATE OF oDlg It always shows the checkbox checked when starting. It is the same in the sample program "datetime.prg".
dtpicker and empty date
Gale, Please review this topic: <!-- m --><a class="postlink" href="http://fivetechsoft.com/forums/viewtopic.php?t=3181">http://fivetechsoft.com/forums/viewtopic.php?t=3181</a><!-- m -->
dtpicker and empty date
Ok, I created a prg with the code included in that conversation. Linked it into the sample program datetime.prg. Still did not work. When the control with the empty date ( 3rd control ) is initialized it has the check mark. It will not start with it unchecked (blank). It does not work right. By the way, I had already tried that code in my program with no luck but I thought I would try it again with the sample program.
dtpicker and empty date
I noticed that the code used in the conversation that you linked to refers to a function called setdatepic(). The code calls setdatepic() with 5 parameters, with the 5th one a 0 or 1 depending on whether the date is empty or not. When I look at the source code for the setdatepic() function it does not make use of the 5th parameter. Is there an update for this function or other code that I do not have access to that would allow the control to start with no date?
dtpicker and empty date
Gale, here is the updated function in datepick.c [code:1uslehad]HB_FUNC&#40; SETDATEPICK &#41; // &#40; hWnd, wYear, wMonth, wDay, GTD_NONE &#41; &#123; SYSTEMTIME sysTime; sysTime&#46;wYear = _parni&#40; 2 &#41;; sysTime&#46;wMonth = _parni&#40; 3 &#41;; sysTime&#46;wDay = _parni&#40; 4 &#41;; sysTime&#46;wDayOfWeek = 0; sysTime&#46;wHour = 0; sysTime&#46;wMinute = 0; sysTime&#46;wSecond = 0; sysTime&#46;wMilliseconds = 0; SendMessage&#40; &#40; HWND &#41; _parnl&#40; 1 &#41;, DTM_SETSYSTEMTIME, _parni&#40;5&#41;, &#40; LPARAM &#41; &sysTime &#41;; &#125; [/code:1uslehad] Stefan
dtpicker and empty date
Gale, This is the modfied Class TDTPicket Method SetDate() using the previous function change: [code:2qvvwpg9] METHOD SetDate&#40; dDate, lEmpty &#41; INLINE SetDatePick&#40; &#58;&#58;hWnd, Year&#40; dDate &#41;,; Month&#40; dDate &#41;, Day&#40; dDate &#41;,; If&#40; lEmpty != nil &#46;and&#46; lEmpty, 1, 0 &#41; &#41; [/code:2qvvwpg9]
dtpicker and empty date
I'm sorry but I cannot get this to work. I get errors trying to compile the c code provided. Also, DTPicker does not call setdate() with the second parameter anywhere that I could see. Does anybody have this working?
dtpicker and empty date
I appreciate the code Stefan but I use xHarbour professional and I cannot get the code to compile without errors. Gale
dtpicker and empty date
Would someone send me a compiled datepick.c that include the changes above. I will try to work out the rest. Thanks, Gale
dtpicker and empty date
Gale, Try it this way. Please include this code in your main PRG: [code:3cwxrop3] #pragma BEGINDUMP #include <hbapi&#46;h> #include <windows&#46;h> HB_FUNC&#40; SETDATEPICK &#41; // &#40; hWnd, wYear, wMonth, wDay, GTD_NONE &#41; &#123; SYSTEMTIME sysTime; sysTime&#46;wYear = hb_parni&#40; 2 &#41;; sysTime&#46;wMonth = hb_parni&#40; 3 &#41;; sysTime&#46;wDay = hb_parni&#40; 4 &#41;; sysTime&#46;wDayOfWeek = 0; sysTime&#46;wHour = 0; sysTime&#46;wMinute = 0; sysTime&#46;wSecond = 0; sysTime&#46;wMilliseconds = 0; SendMessage&#40; &#40; HWND &#41; hb_parnl&#40; 1 &#41;, DTM_SETSYSTEMTIME, hb_parni&#40;5&#41;, &#40; LPARAM &#41; &sysTime &#41;; &#125; #pragma ENDDUMP [/code:3cwxrop3] ACTIVATE DIALOG oDlg ; ON INIT oBegDate:SetDate( nil, .T. )
dtpicker and empty date
Thanks Antonio I have it working now. I had to add #include <commctrl.h> I am a little embarrassed because I was placing the #pragma after the include statements. Now life is good. Here is the code I am using. Datepick.prg [code:1vxxb802] #pragma BEGINDUMP #include <hbapi&#46;h> #include <windows&#46;h> #include <commctrl&#46;h> HB_FUNC&#40; SETDATEPICK &#41; // &#40; hWnd, wYear, wMonth, wDay, GTD_NONE &#41; &#123; SYSTEMTIME sysTime; sysTime&#46;wYear = hb_parni&#40; 2 &#41;; sysTime&#46;wMonth = hb_parni&#40; 3 &#41;; sysTime&#46;wDay = hb_parni&#40; 4 &#41;; sysTime&#46;wDayOfWeek = 0; sysTime&#46;wHour = 0; sysTime&#46;wMinute = 0; sysTime&#46;wSecond = 0; sysTime&#46;wMilliseconds = 0; SendMessage&#40; &#40; HWND &#41; hb_parnl&#40; 1 &#41;, DTM_SETSYSTEMTIME, hb_parni&#40;5&#41;, &#40; LPARAM &#41; &sysTime &#41;; &#125; #pragma ENDDUMP [/code:1vxxb802] tDtPicker.prg [code:1vxxb802] #include "FiveWin&#46;ch" #include "constant&#46;ch" #define COLOR_WINDOW 5 #define COLOR_WINDOWTEXT 8 #define CS_DBLCLKS 8 #define DTS_SHOWNONE 0x0002 #ifdef __XPP__ #define Super &#58;&#58;TControl #define New _New #endif //----------------------------------------------------------------------------// CLASS TDatePick FROM TControl CLASSDATA lRegistered DATA lEmptyDate METHOD New&#40; nRow, nCol, bSetGet, oWnd, nWidth, nHeight, bValid, nClrFore,; nClrBack, oFont, lDesign, oCursor, lPixel, cMsg, lUpdate,; bWhen, bChange, nHelpId,lEmp&#41; CONSTRUCTOR METHOD ReDefine&#40; nId, bSetGet,oWnd, nHelpId, cMsg, lUpdate, bWhen, bValid&#41; CONSTRUCTOR METHOD cText&#40; cText &#41; SETGET METHOD cToChar&#40;&#41; INLINE Super&#58;cToChar&#40; "SysDateTimePick32" &#41; METHOD Initiate&#40; hDlg &#41; METHOD SetDate&#40; dDate &#41; // Modificado fgondi METHOD GetDate&#40;&#41; INLINE GetDatePick&#40; &#58;&#58;hWnd &#41; METHOD LostFocus&#40; hCtrl &#41; METHOD Change&#40;&#41; METHOD Changed&#40;&#41; INLINE &#40; Eval&#40; &#58;&#58;bSetGet, &#58;&#58;GetDate&#40;&#41; &#41;, &#58;&#58;Change&#40;&#41; &#41; METHOD Refresh&#40;&#41; INLINE &#58;&#58;SetDate&#40; Eval&#40; &#58;&#58;bSetGet &#41; &#41; ENDCLASS //----------------------------------------------------------------------------// METHOD New&#40; nRow, nCol, bSetGet, oWnd, nWidth, nHeight, bValid, nClrFore,; nClrBack, oFont, lDesign, oCursor, lPixel, cMsg, lUpdate,; bWhen, bChange, nHelpId, lEmp &#41; Class TDatePick DEFAULT nRow &#58;= 0, nCol &#58;= 0,; oWnd &#58;= GetWndDefault&#40;&#41;,; nWidth &#58;= 100,; nHeight &#58;= If&#40; oFont != nil, oFont&#58;nHeight, 22 &#41;,; nClrFore &#58;= GetSysColor&#40; COLOR_WINDOWTEXT &#41;,; nClrBack &#58;= GetSysColor&#40; COLOR_WINDOW &#41;,; oFont &#58;= oWnd&#58;oFont,; nHelpId &#58;= 100,; lDesign &#58;= &#46;f&#46;,; lPixel &#58;= &#46;f&#46;,; lUpdate &#58;= &#46;f&#46;,; lEmp &#58;= &#46;t&#46; &#58;&#58;cCaption = "" &#58;&#58;nTop = nRow * If&#40; ! lPixel, BTN_CHARPIX_H, 1 &#41; &#58;&#58;nLeft = nCol * If&#40; ! lPixel, BTN_CHARPIX_W, 1 &#41; &#58;&#58;nBottom = &#58;&#58;nTop + nHeight &#58;&#58;nRight = &#58;&#58;nLeft + nWidth &#58;&#58;nHelpId = nHelpId &#58;&#58;oWnd = oWnd &#58;&#58;oFont = oFont &#58;&#58;bSetGet = bSetGet &#58;&#58;lEmptyDate &#58;= lEmp &#58;&#58;lEmptyDate &#58;= &#46;t&#46; if !lEmp &#58;&#58;nStyle = nOR&#40; WS_CHILD, WS_VISIBLE, WS_TABSTOP,; If&#40; lDesign, WS_CLIPSIBLINGS, 0 &#41; &#41; else &#58;&#58;nStyle = nOR&#40; WS_CHILD, WS_VISIBLE, WS_TABSTOP, DTS_SHOWNONE,; If&#40; lDesign, WS_CLIPSIBLINGS, 0 &#41; &#41; endif &#58;&#58;nId = &#58;&#58;GetNewId&#40;&#41; &#58;&#58;lDrag = lDesign &#58;&#58;lCaptured = &#46;f&#46; &#58;&#58;cMsg = cMsg &#58;&#58;lUpdate = lUpdate &#58;&#58;bWhen = bWhen &#58;&#58;bValid = bValid &#58;&#58;bChange = bChange InitCommon&#40;&#41; if ! Empty&#40; oWnd&#58;hWnd &#41; &#58;&#58;Create&#40; "SysDateTimePick32" &#41; oWnd&#58;AddControl&#40; Self &#41; if oFont != nil &#58;&#58;SetFont&#40; oFont &#41; endif else oWnd&#58;DefControl&#40; Self &#41; endif if lDesign &#58;&#58;CheckDots&#40;&#41; endif return Self //----------------------------------------------------------------------------// METHOD ReDefine&#40; nId, bSetGet, oWnd, nHelpId, nClrFore, nClrBack,; oFont, oCursor, cMsg, lUpdate, bWhen, bValid, bChanged &#41; Class TDatePick DEFAULT oWnd &#58;= GetWndDefault&#40;&#41;,; nClrFore &#58;= GetSysColor&#40; COLOR_WINDOWTEXT &#41;,; nClrBack &#58;= GetSysColor&#40; COLOR_WINDOW &#41;,; lUpdate &#58;= &#46;f&#46; &#58;&#58;nId = nId &#58;&#58;hWnd = 0 &#58;&#58;nHelpId = nHelpId &#58;&#58;oWnd = oWnd &#58;&#58;oFont = oFont &#58;&#58;oCursor = oCursor &#58;&#58;lCaptured = &#46;f&#46; &#58;&#58;lDrag = &#46;f&#46; &#58;&#58;cMsg = cMsg &#58;&#58;lUpdate = lUpdate &#58;&#58;bWhen = bWhen &#58;&#58;bValid = bValid &#58;&#58;bSetGet = bSetGet &#58;&#58;bChange = bChanged &#58;&#58;lEmptyDate &#58;= &#46;t&#46; InitCommon&#40;&#41; &#58;&#58;Register&#40;&#41; oWnd&#58;DefControl&#40; Self &#41; return Self METHOD Initiate&#40; hDlg &#41; Class TDatePick Super&#58;Initiate&#40; hDlg &#41; &#58;&#58;cText = Eval&#40; &#58;&#58;bSetGet &#41; return nil METHOD cText&#40; uVal &#41; CLASS TDatePick if PCount&#40;&#41; == 1 Eval&#40; &#58;&#58;bSetGet, uVal &#41; &#58;&#58;SetDate&#40; uVal &#41; &#58;&#58;Refresh&#40;&#41; &#58;&#58;Change&#40;&#41; endif return &#58;&#58;GetDate&#40;&#41; //---------------------------------------------------------------------------// // Controlo si la fecha esta vacia para quitar la marca del checkbox incluido en el campo // El quinto parametro indica el estado del checkbox&#46; 0 Marcado, 1 Desmarcado&#46; METHOD SetDate&#40; dDate &#41; CLASS TDatePick local dShow local dDat &#58;= dDate if empty&#40; dDate &#41; dDat &#58;= if&#40; !&#58;&#58;lEmptyDate, date&#40;&#41;, dDate &#41; endif dShow &#58;= dDat SetDatePick&#40; &#58;&#58;hWnd, Year&#40; dShow &#41;, Month&#40; dShow &#41;, Day&#40; dShow &#41;, 0 &#41; if Empty&#40;dDate&#41; SetDatePick&#40; &#58;&#58;hWnd, Year&#40; dShow &#41;, Month&#40; dShow &#41;, Day&#40; dShow &#41;, 1 &#41; endif return Self METHOD LostFocus&#40; hCtrl &#41; CLASS TDatePick Eval&#40; &#58;&#58;bSetGet, &#58;&#58;cText &#41; return Super&#58;LostFocus&#40; hCtrl &#41; METHOD Change&#40;&#41; CLASS TDatePick if &#58;&#58;bChange != nil Eval&#40; &#58;&#58;bChange, Self &#41; endif return nil [/code:1vxxb802] Thanks everyone, Gale
dtpicker and empty date
Gale, glad to know you got it working <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
dtpicker no recibe el foco...
Amigos : He revisado que el control dtpicker no recibe el foco cuando se le asigna desde un btnbmp despues de ejecutar una accion, disparada con enter con click si toma el foco. Gracias. Sakudos Dario Fernandez
dtpicker vacia...
Alguna forma de que el dtpicker me muestre la fecha vacia y poder yo seleccionarla, algo asi: dFec:=CTOD("") Redefine dtpicker dFec ....... tambien tengo un campo date y vacio si cargo la variable al dtpicker me muestra la fecha actual, como hacer que no ponga fecha? salu2 paco
dtpicker vacia...
Paco, Parece que no hay manera. Aunque se haga: SetDatePick( oDTP:hWnd, 0, 0, 0 ) muestra la fecha actual
dtpicker vacia...
gracias antonio salu2 paco
dtpicker y dialogo transparente no refresca correctamente
Parece que hay un problema con dtpicker cuando se usa la clausula transparent en un dialogo Sucede que al usar dicha clausula y seleccionar una fecha del calendario, la fecha seleccionada se empalma sobre la fecha anterior, y cuando se cambia el dato del dia mes o año manualmente el color se cambia a un ilegible color azul oscuro con letras negras, y parece ser que hasta el tabstop se desactiva. Probe compilando con harbour y xharbour y sucede lo mismo. Este efecto se puede ver en el ejemplo que viene con fwh (datetime.prg) al poner la clausula transparent en el dialogo. [code=fw:2tlfm0kw]<div class="fw" id="{CB}" style="font-family: monospace;"> Date picker and Time picker samples<br /><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"FiveWin.ch"</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"dtpicker.ch"</span><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><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, aGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span>, aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span>, aSAY<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span><br /><br />   Set Date British<br />   <br />   <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Main"</span> transparent<br /><br />   aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span> := Date<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">REDEFINE</span> DTPicker aGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">VAR</span> aVAR<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;">120</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg<br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">SAY</span> aSAY<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;">130</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg<br /><br />   aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#93;</span> := Date<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">REDEFINE</span> DTPicker aGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">VAR</span> aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">121</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg<br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">SAY</span> aSAY<span style="color: #000000;">&#91;</span><span style="color: #000000;">2</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">131</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg<br /><br />   aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">3</span><span style="color: #000000;">&#93;</span> := ctod<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">''</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">REDEFINE</span> DTPicker aGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">3</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">VAR</span> aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">3</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">122</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg<br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">SAY</span> aSAY<span style="color: #000000;">&#91;</span><span style="color: #000000;">3</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">132</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg<br /><br />   aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">4</span><span style="color: #000000;">&#93;</span> := Hora<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">REDEFINE</span> TMPicker aGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">4</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">VAR</span> aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">4</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">123</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg <br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">SAY</span> aSAY<span style="color: #000000;">&#91;</span><span style="color: #000000;">4</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">133</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg<br /><br />   aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span> := <span style="color: #ff0000;">''</span><br />   <span style="color: #0000ff;">REDEFINE</span> TMPicker aGet<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">VAR</span> aVAR<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">124</span> <span style="color: #0000ff;">UPDATE</span> <span style="color: #0000ff;">OF</span> oDlg <br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">SAY</span> aSAY<span style="color: #000000;">&#91;</span><span style="color: #000000;">5</span><span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">134</span> <span style="color: #0000ff;">UPDATE</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> IDOK <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">ACTION</span> ps_Show<span style="color: #000000;">&#40;</span>aGet, aSAY<span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">4</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">ACTION</span> ps_Clean<span style="color: #000000;">&#40;</span>aSAY<span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> IDCANCEL <span style="color: #0000ff;">OF</span> oDlg <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 />   <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTERED</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">static</span> proc ps_Show<span style="color: #000000;">&#40;</span>aGet, aSAY<span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">local</span> i, xValor<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>aGet<span style="color: #000000;">&#41;</span><br />     xValor := Eval<span style="color: #000000;">&#40;</span>aGet<span style="color: #000000;">&#91;</span>i<span style="color: #000000;">&#93;</span>:<span style="color: #000000;">bSetGet</span><span style="color: #000000;">&#41;</span><br />     xValor := <span style="color: #00C800;">if</span><span style="color: #000000;">&#40;</span> Empty<span style="color: #000000;">&#40;</span>xValor<span style="color: #000000;">&#41;</span>, <span style="color: #ff0000;">'EMPTY'</span>, xValor <span style="color: #000000;">&#41;</span><br />     xValor := <span style="color: #00C800;">if</span><span style="color: #000000;">&#40;</span> Valtype<span style="color: #000000;">&#40;</span>xValor<span style="color: #000000;">&#41;</span>=<span style="color: #ff0000;">'D'</span>, dtoc<span style="color: #000000;">&#40;</span>xValor<span style="color: #000000;">&#41;</span>, xValor <span style="color: #000000;">&#41;</span><br />     aSAY<span style="color: #000000;">&#91;</span>i<span style="color: #000000;">&#93;</span>:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span> xValor <span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">next</span><br /><span style="color: #00C800;">return</span><br /><br /><span style="color: #00C800;">static</span> proc ps_Clean<span style="color: #000000;">&#40;</span>aSAY<span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">local</span> i, xValor<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>aSAY<span style="color: #000000;">&#41;</span><br />     aSAY<span style="color: #000000;">&#91;</span>i<span style="color: #000000;">&#93;</span>:<span style="color: #000000;">SetText</span><span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">''</span> <span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">next</span><br /><span style="color: #00C800;">return</span><br /><br /><span style="color: #00C800;">FUNCTION</span> Hora<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />  <span style="color: #00C800;">local</span> nAux, nMin, nHor, nSec, cMin, cHor, cSec<br />  nSec := Seconds<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />  nAux := Int<span style="color: #000000;">&#40;</span>nSec<span style="color: #000000;">&#41;</span> / <span style="color: #000000;">3600</span><br />  nHor := Int<span style="color: #000000;">&#40;</span>nAux<span style="color: #000000;">&#41;</span><br />  nAux := <span style="color: #000000;">&#40;</span>nAux - nHor<span style="color: #000000;">&#41;</span> * <span style="color: #000000;">60</span><br />  nMin := Int<span style="color: #000000;">&#40;</span>nAux<span style="color: #000000;">&#41;</span><br />  nSec := Int<span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span>nAux - nMin<span style="color: #000000;">&#41;</span> * <span style="color: #000000;">60</span> <span style="color: #000000;">&#41;</span><br />  cHor := Padl<span style="color: #000000;">&#40;</span> alltrim<span style="color: #000000;">&#40;</span>str<span style="color: #000000;">&#40;</span>nHor<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">2</span>, <span style="color: #ff0000;">'0'</span><span style="color: #000000;">&#41;</span><br />  cMin := Padl<span style="color: #000000;">&#40;</span> alltrim<span style="color: #000000;">&#40;</span>str<span style="color: #000000;">&#40;</span>nMin<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">2</span>, <span style="color: #ff0000;">'0'</span><span style="color: #000000;">&#41;</span><br />  cSec := Padl<span style="color: #000000;">&#40;</span> alltrim<span style="color: #000000;">&#40;</span>str<span style="color: #000000;">&#40;</span>nSec<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span>, <span style="color: #000000;">2</span>, <span style="color: #ff0000;">'0'</span><span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">return</span> cHor + cMin + cSec</div>[/code:2tlfm0kw] [/code] Si refrescamos el dtpicker usando aGet[1]:refresh() el problema persiste. Si se usa oDlg:refresh() el problema solo se corrige parcialmente. ¿Alguien tiene la solucion a dicho problema?. Saludos
dtpicker y dialogo transparente no refresca correctamente
Aqui un ejemplo del error [img:3awdyfbb]http&#58;//www&#46;lanominamasfacil&#46;com&#46;mx/pantalla&#46;JPG[/img:3awdyfbb] Saludos
dtpicker y dialogo transparente no refresca correctamente
Una solucion no muy ortodoxa es: REDEFINE DTPicker aGet[1] VAR aVAR[1] ID 120 UPDATE OF oDlg ON CHANGE oDlg:refresh() soluciona el problema pero se produce un feo efecto al refrescar el dialogo. saludos.
dtpicker y dialogo transparente no refresca correctamente
Saludos. Jose usted simpre soluciono este problema con la fecha que no refresca. Ya que tengo el miismo problema.
dtpicker y dialogo transparente no refresca correctamente
Hola Ruben La unica forma que encontre de solucionar el problema es refrescar el dialogo (o el folder) cada vez que cambias un dato de la fecha y al salir de la misma. Refrescar solo el dtpicker no soluciona el problema. [code=fw:135wgv87]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #0000ff;">REDEFINE</span> DTPICKER oFCompraTerr <span style="color: #0000ff;">var</span> WM_dFCompraTerr;<br />                       <span style="color: #0000ff;">on</span> <span style="color: #0000ff;">change</span> <span style="color: #000000;">&#40;</span>oFld:<span style="color: #000000;">aDialogs</span><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><span style="color: #000000;">&#41;</span>;<br />                       <span style="color: #0000ff;">ID</span> <span style="color: #000000;">100</span> <span style="color: #0000ff;">OF</span> oFld:<span style="color: #000000;">aDialogs</span><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span><br /><br />         oFCompraTerr:<span style="color: #000000;">bLostFocus</span>:=<span style="color: #000000;">&#123;</span>|| oFld:<span style="color: #000000;">aDialogs</span><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><span style="color: #000000;">&#125;</span><br /> </div>[/code:135wgv87] No es la solucion optima porque se ve a cada rato el refresh de la pantalla pero funciona. Saludos Jose Rios
duda Antonio !!!
Quiero utilizar la version 2.7 de FWH, pero la quiero con xharbour que tengo que utilizar, veo que la carpeta de lib solo viene five.lib, fivec.lib y otras, espero que me puedas orientar por favor. tambien cuando utilizo verce me pide para xharbour Fivehx.lib, esta libreria la tengo en la version fw2.6 que debo hacer para generar mi ambiente de trabajo... saludos
duda Antonio !!!
Five.lib y FiveC.lib son las librerías de FiveWin para Clipper 16 bits, no para Harbour 32 bits.
duda Antonio !!!
Tengo que crear las ibrerias para harbour o xharbour,
duda Antonio !!!
FWH (FiveWin para Harbour/xharbour) es un producto distinto a FW (FiveWin para Clipper), aunque son compatibles. No puedes crear las librerías de FWH a partir de las de FW. Tienes que adquirir FWH desde <!-- w --><a class="postlink" href="http://www.fivetechsoft.com">www.fivetechsoft.com</a><!-- w --> sección pedidos
duda Antonio !!!
una pregunta la version de fw 27 es solo para 16 bits o es para 32 bits. tabien por decir quiero compilar las classes de fwh que flags debo utilizar tanto para harbour como para bcc55, saludos
duda Antonio !!!
FW es para Clipper. FWH es para Harbour/xharbour. Los flags de compilación se indican en samples\build.bat y buildh.bat
duda Antonio !!!
una pregunta Antonio: busque aqui un error que es este cuando recompilas la libreria de fiveh.lib me manda un error en BYNAME
duda Antonio !!!
<!-- m --><a class="postlink" href="http://fivetechsoft.com/forums/viewtopic.php?t=7595">http://fivetechsoft.com/forums/viewtopic.php?t=7595</a><!-- m -->
duda !!! activex
saludos si alguien me pudiera apoyar tengo fw 27, lo curiosa es que cuenta con activex pero no he podido compilar ningun ejemplos de samples me manda este error ACTIVEX.OBJ(ACTIVEX) : 'ACTXGETPRO' : unresolved external y otras que me hace falta o no la soporta.
duda !!! activex
En esa versión no está implementado, solo había un prototipo que aún no funcionaba.
duda ? Popup Control
saludos: mi siguiente pregunta es saber si alguien en el foro ha a desarollado una classe Popup Control, espero que me entiendan, he estado trabajando en este control saludos.Ado
duda ? Popup Control
Te refieres a un menu popup ?Puedes explicar un poco más que tipo de control es ? Algún ejemplo ? gracias
duda ? Popup Control
gracias por responder Antonio. bueno creo que fui algo corto en explicarme, no es un menu popup, es como una ventana que aparece en cualquier parte de las esquinas de la pantalla principal, como un mensaje, este efecto lo he visto en el Outlook o en el messanger cuando recibes un correo nuevo. tengo una imagen pero no se como montarla para que la veas.saludos
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Hola compañeros, Para buscar un valor en todos los campos ahora uso: cWild := "*"+ "VALOR A BUSCAR" +"*" cFiltro := "hb_WildMatch( '"+cWild+"', DbRecordInfo( 9 ) ) .OR. hb_WildMatch( '"+UPPER(cWild)+"', DbRecordInfo( 9 ) ) .or. hb_WildMatch( '"+lower(cWild)+"', DbRecordInfo( 9 ) ) " SET FILTER TO &cFiltro Y funciona muy bien, pero ADS no lo soporta. He probado con: cName := "LUCAS" cExpr1 := 'contains( *, "*'+UPPER( alltrim(cName) )+'*" ) ' AdsSetAOF( cExpr1 ) Y nada. ¿Alguno sabe cómo resolverlo por favor?. Gracias.
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Lucas; a ver si te ayuda. El filtro ADS lo uso así: [code=fw:1nioel58]<div class="fw" id="{CB}" style="font-family: monospace;">cName := <span style="color: #ff0000;">"LUCAS"</span><br /><span style="color: #B900B9;">// que comience</span><br />AdsSetAOF<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">'APEYNOM="'</span> +cName+<span style="color: #ff0000;">'"'</span> <span style="color: #000000;">&#41;</span><br /><span style="color: #B900B9;">// que contenga</span><br />AdsSetAOF<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">'"'</span> +cName+ <span style="color: #ff0000;">'" $ APEYNOM'</span> <span style="color: #000000;">&#41;</span></div>[/code:1nioel58]
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Muchas gracias Mario, pero se trata de buscar en todos los campos. Eso es lo que permite el código anteriormente indicado. Además, funciona bastante bien con DBFCDX. ¿Tu haces este tipo de búsquedas totales?. Muchas gracias de nuevo.
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
lamento decirte que no Otra opcion, con ADS, es hacerlo mediante sentencia SQL, que es lo que uso para casos como el que planteas. Si no tenes la ayuda de sentencias te la paso
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
[quote="lucasdebeltran":17oiawj8]Muchas gracias Mario, pero se trata de buscar en todos los campos. Eso es lo que permite el código anteriormente indicado. Además, funciona bastante bien con DBFCDX. ¿Tu haces este tipo de búsquedas totales?. Muchas gracias de nuevo.[/quote:17oiawj8] Quizás esto te sirva: [code=fw:17oiawj8]<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;">"Dbstruct.ch"</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"DbInfo.ch"</span><br /><br /><span style="color: #B900B9;">/* Función para buscar en una DBF (en su orden NATURAL) un valor contenido<br />   en un campo determinado.<br />   Simula el comando LOCATE y CONTINUE, pero realizando un AT().<br />   Devuelve el Recno() ó '0' según encuentre o no el valor a buscar.<br />   Se asume que la DBF está abierta y se recibe su Alias().<br /><br />   Su uso es:<br />   nAtInDbf( cAliasDBF, "APELLIDO", "GARCIA", .F. )<br /><br />   para continuar la búsqueda con los mismos parámetros:<br />   nAtInDbf( cAliasDBF, , , .T. )<br /><br />   Para que nos entendamos, la primera vez vendría a ser un LOCATE, y la segunda<br />   vez vendría a ser un CONTINUE.<br /><br />   --------------------------------------------------------------------------------- */</span><br /><br /><span style="color: #00C800;">FUNCTION</span> nAtInDbf<span style="color: #000000;">&#40;</span> cAliasDBF, cFieldDBF, cString, lContinue <span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">STATIC</span> cMemoDbf       := <span style="color: #ff0000;">""</span>, ;<br />       nBytesToField  := <span style="color: #000000;">0</span>, ;<br />       nBytesEndField := <span style="color: #000000;">0</span>, ;<br />       nOffset        := <span style="color: #000000;">0</span>, ;<br />       cSearch        := <span style="color: #ff0000;">""</span>, ;<br />       cfield         := <span style="color: #ff0000;">""</span>, ;<br />       nRegLocate_1   := <span style="color: #000000;">0</span><br /><br /><span style="color: #00C800;">Local</span> aEstruct     := <span style="color: #000000;">&#123;</span><span style="color: #000000;">&#125;</span><br /><span style="color: #00C800;">Local</span> nPos         := <span style="color: #000000;">0</span><br /><br /><span style="color: #00C800;">DEFAULT</span> lContinue := .F.<br /><br /><span style="color: #B900B9;">/*<br />Traza( 1, cAliasDbf )<br />Traza( 1, ( cAliasDbf )->(DbInfo( DBI_FULLPATH )) )<br />Traza( 1, cFieldDbf )<br />Traza( 1, cString )<br />Traza( 1, lContinue )<br />*/</span><br /><br /><span style="color: #00C800;">If</span> .not. lContinue<br />    <span style="color: #00C800;">If</span> Len<span style="color: #000000;">&#40;</span> cString <span style="color: #000000;">&#41;</span> < <span style="color: #000000;">1</span><br />        <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Not Data to Search."</span>, <span style="color: #ff0000;">"Search Error."</span> <span style="color: #000000;">&#41;</span><br />        <span style="color: #00C800;">Return</span> <span style="color: #000000;">0</span><br />    <span style="color: #00C800;">Endif</span><br />    cMemoDbf       := MemoRead<span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span> cAliasDbf <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>DbInfo<span style="color: #000000;">&#40;</span> DBI_FULLPATH <span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />    nOffset        := <span style="color: #000000;">0</span><br />    cSearch        := cString<br />    cField         := Upper<span style="color: #000000;">&#40;</span> cfieldDBF <span style="color: #000000;">&#41;</span><br />    nRegLocate_1   := <span style="color: #000000;">0</span><br /><br />    nBytesToField  := <span style="color: #000000;">0</span><br />    nBytesEndField := <span style="color: #000000;">0</span><br /><br />    aEstruct       := <span style="color: #000000;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>DBSTRUCT<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />    AScan<span style="color: #000000;">&#40;</span> aEstruct, <span style="color: #000000;">&#123;</span> |aCampo| <span style="color: #00C800;">If</span><span style="color: #000000;">&#40;</span> aCampo<span style="color: #000000;">&#91;</span> DBS_NAME <span style="color: #000000;">&#93;</span> == cField, ;<br />                                    <span style="color: #000000;">&#40;</span>nBytesEndField := nBytesToField + aCampo<span style="color: #000000;">&#91;</span> DBS_LEN <span style="color: #000000;">&#93;</span> + aCampo<span style="color: #000000;">&#91;</span> DBS_DEC <span style="color: #000000;">&#93;</span>, .T.<span style="color: #000000;">&#41;</span>, ;<br />                                    <span style="color: #000000;">&#40;</span>nBytesToField := nBytesToField + aCampo<span style="color: #000000;">&#91;</span> DBS_LEN <span style="color: #000000;">&#93;</span> + aCampo<span style="color: #000000;">&#91;</span> DBS_DEC <span style="color: #000000;">&#93;</span>, .F. <span style="color: #000000;">&#41;</span> ;<br />                                  <span style="color: #000000;">&#41;</span> ;<br />                     <span style="color: #000000;">&#125;</span> ;<br />         <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">If</span> nBytesEndField = <span style="color: #000000;">0</span><br />        <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Field not found."</span>, <span style="color: #ff0000;">"Search Error."</span> <span style="color: #000000;">&#41;</span><br />        <span style="color: #00C800;">Return</span> <span style="color: #000000;">0</span><br />    <span style="color: #00C800;">Endif</span><br /><br /><span style="color: #00C800;">EndIf</span><br /><br />nPos := <span style="color: #000000;">0</span><br /><span style="color: #00C800;">While</span> nPos <= <span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>Header<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> + <span style="color: #000000;">&#40;</span>nRegLocate_1 * <span style="color: #000000;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>RecSize<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> + nBytesToField<span style="color: #000000;">&#41;</span> .or. ;<br />      nPos > <span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>Header<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> + <span style="color: #000000;">&#40;</span>nRegLocate_1 * <span style="color: #000000;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>RecSize<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> + nBytesEndField<span style="color: #000000;">&#41;</span><br /><br />    nPos      := <span style="color: #00C800;">AT</span><span style="color: #000000;">&#40;</span> cSearch, <span style="color: #0000ff;">SubStr</span><span style="color: #000000;">&#40;</span>cMemoDbf, nOffset + <span style="color: #000000;">1</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br /><br />    <span style="color: #00C800;">If</span> nPos = <span style="color: #000000;">0</span><br />        nRegLocate_1 = <span style="color: #000000;">-1</span><br />        Exit<br />    <span style="color: #00C800;">EndIf</span><br /><br />    nOffset := nPos := nPos + nOffSet<br /><br />    nRegLocate_1 := INT<span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#40;</span> nPos - <span style="color: #000000;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>Header<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;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>RecSize<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: #B900B9;">// Registro anterior al localizado¿?</span><br /><br />    <span style="color: #00C800;">If</span> <span style="color: #000000;">&#40;</span><span style="color: #000000;">&#40;</span> nPos - <span style="color: #000000;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>Header<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;">&#40;</span> cAliasDBF <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span>RecSize<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;">0</span><br />        nRegLocate_1 = nRegLocate_1 - <span style="color: #000000;">1</span>  <span style="color: #B900B9;">// Registro anterior al localizado.</span><br />    <span style="color: #00C800;">EndIf</span><br /><br />End<br /><br /><span style="color: #00C800;">Return</span> nRegLocate_1 + <span style="color: #000000;">1</span><br /><span style="color: #B900B9;">//------------------------------------------------------------------</span><br /> </div>[/code:17oiawj8]
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Hola: Muchas gracias pero no me sirve ya que al usar ADS no se puede abrir el fichero a bajo nivel.
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Para usar la instrucción containsnNecesitas crear indices FTS sobre la tabla que quieras buscar. [code=fw:b7u58fcf]<div class="fw" id="{CB}" style="font-family: monospace;">cExpr1 := <span style="color: #ff0000;">'contains( *, "*'</span>+UPPER<span style="color: #000000;">&#40;</span> alltrim<span style="color: #000000;">&#40;</span>cName<span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>+<span style="color: #ff0000;">'*" ) '</span></div>[/code:b7u58fcf] Revisa la ayuda de ADS sobre los indices FTS. Son una maravilla.
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Hola Fernando: Muchas gracias por responder. Lo del * para todos los campos ya lo descubrí en la ayuda, pero no se cómo crear un índice FTS para todos los campos. ¿Por favor, tienes un ejemplo?. Y los índices FTS ¿son temproales o son como los .cdx?. No he conseguido encontrar información sobre índices FTS y Harbour. Un saludo y mil gracias de nuevo.
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Lucas: en el Help del Arc de Advantage habla de los indices FTS, quizas te pueda ayudar. Saludos Ruben Fernandez
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Los indices FTS no son de Harbour, son de Advantage. Revisa la ayuda del Arc de Advantage, como te dice Ruben Fernandez.
duda ADS equivalente hb_WildMatch( '""+cWild+""' DbRecordInfo
Sí, claro que lo miré, pero no lo entendí bien, sobre todo con el uso de un Diccionario para usar las Dbfs via AIS. Todavía tengo el problema con los índices. Con AIS, INDEX ON NUMERO TO PRESUA FOR PASADO = "S" .AND. !Deleted() no me genera un .IDX sino un .[b:wv6ot0i4]CDX[/b:wv6ot0i4]. No lo entiendo. En modo local sí me genera un .[b:wv6ot0i4]IDX[/b:wv6ot0i4], pero en modo AIS es un .cdx con el mismo código.
duda Aeval
Hola, Tengo un array multidimensional y quiero reemplazar los elementos que tengan nil por otra cosa. Lo ago así: AEVAL(aArray,; {|cValue,n| IF(cValue = nil,; aArray[n] := "nada",)}) Pero únicamente me cambia las cinco primeras columnas (tiene seis) de la primera línea. ¿Qué hago mal?. Muchas gracias.
duda Aeval
Buenas tardes Puede ser porque el tipo de cValue sea "A", no?, ya que el array es multidimensional y cada elemento de aArray es otro array, y AEval no lo recorre. Espero que pueda servirte de algo y haberme explicado. Un saludo
duda Aeval
lucas prueba asi: aArray := { {"1","",25},; {"2",nil,35},; {"3","tres",45} } hablando de un multidimensional, para valor nulo en la posicion 2 de tu arreglo: AEVAL(aArray,; {|cValue,n| IF( aArray[n,2] = nil .or empty(aArray[n,2]),; aArray[n,2] := "nada",)}) te quedaria asi: aArray := { {"1","nada",25},; {"2","nada",35},; {"3","tres",45} } saludos paco
duda Aeval
Buenas tardes de nuevo Yo no he conseguido "anidar" AEval para recorrer arrays multidimensionales. Puedes intentar hacer algo asi: Function Prueba() Local aTabla := { {0,0},{0,1},{0,2},{0,3},{0,4},{0,5} } //AEVal( aTabla , { | nV , nEle | Msginfo( Str(nV[1])+Str( nEle ) ) } ) AEVal( aTabla , { | nV , nEle | Porelarray( nV ) } ) //AEVal( aTabla , { | nV , nEle | Msginfo( Str(nV[1])+Str( nEle ) ) } ) //AEVal( aTabla , { | nV , nEle | Msginfo( Str(nV[2])+Str( nEle ) ) } ) Return nil Function Porelarray( aT ) ; Return AEVal( aT , { | nV1 , nEle1 | if( nV1 = 0, aT[nEle1] := 99, ) }) Un saludo
duda Ribbon
Hola: Al hacer más pequeña la ventana WndMain con una ribbon, o bien porque la resolución del usuario es menor y no caben todos los botones, ¿sería posible que el control hiciera más pequeños los bitmaps de los botones para hacer el reajuste automáticamente? Así lo hace Office por ejemplo. Muchas gracias. Un saludo
duda Ribbon
uP!
duda Ribbon
Moisés, poderse se puede, evidentemente, pero requiere programar la clausula ON RESIZE de la ventana principal 1.- Cuando entras en la aplicación, te guardas las dimensiones de la ventana: ancho, alto 2.- En la clausula ON RESIZE de la ventana/dialogo calculas el porcentaje que ha cambiado tanto de alto como de ancho 3.- Este porcentaje se lo aplicas a las dimensiones del RIBBON, y por lo tanto a las dimensiones de cada control que contiene el RIBBON que con un AEVal podrás hacerlo fácilmente aplicado a la DATA :aControls del RIBBON o data equivalente. Es lo que se me ocurre así por encima.
duda TWBrowse
como puedo quitar el espacio en blanco o que me dimensione toda la pantalla del TWBrowse(), quiero poner una imagen pero como la coloco saludos, [/img][/url]
duda TWBrowse
Asi se pone una imagen, cambia los < > por [ ]: <img]http://img132.imageshack.us/img132/9195/picture1xx9.png[/img>
duda TWBrowse
[img:1hbqr9pi]http&#58;//img398&#46;imageshack&#46;us/my&#46;php?image=mandarjw6&#46;png[/img:1hbqr9pi] aqui esta la imagen si alguien tiene la respuesta por favor mandar saludos
duda TWBrowse
Tienes que modificar un poco las dimensiones del browse para que no se vea ese espacio.
duda TWBrowse
gracias antonio por tu respuesta, abusando de tu conocimiento y experiencia en que metodo de la clase de puede modificar las dimenciones del browser gracias Antonio
duda TWBrowse
oBrowse:nHeight = <nValor>
duda TWBrowse
gracias antonio otra cosa estoy usando la clase BTNGET, y quiero que el boton sea trasparente comompuedo hacer eso antonio
duda array
Hola, Tengo un array multidimensional tal que así: [code=fw:3uepd37c]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br />&nbsp; <span style="color: #00C800;">LOCAL</span> aArray := <span style="color: #000000;">&#123;</span> &nbsp; &nbsp;<span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"ORDEN"</span>, &nbsp; &nbsp;<span style="color: #ff0000;">"N"</span>, <span style="color: #000000;">20</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"REFERENCIA"</span>, &nbsp; <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">80</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"NIF"</span>, &nbsp; &nbsp; &nbsp; <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">20</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"NOMBRE"</span>, &nbsp; &nbsp;<span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">80</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"DIRECCION"</span>, <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">80</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"POBLACION"</span>, <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">80</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br /><br />&nbsp;</div>[/code:3uepd37c] Necesito que a todos los campos que tienen "C" y 80 les pueda asignar otro valor de longitud. ¿Cómo se hace automáticamente?. Muy agradecida!.
duda array
Elvira eso es muy fácil... No voy a hacer el programa pero te indico como para que tu lo desarrolles: [code=fw:3lvn10db]<div class="fw" id="{CB}" style="font-family: monospace;"><br />...<br /><br />  <span style="color: #00C800;">LOCAL</span> aArray := <span style="color: #000000;">&#123;</span>    <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"ORDEN"</span>,    <span style="color: #ff0000;">"N"</span>, <span style="color: #000000;">20</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;  <br />                           <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"REFERENCIA"</span>,   <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">80</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br />                           <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"NIF"</span>,       <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">20</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br />                           <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"NOMBRE"</span>,    <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">80</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br />                           <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"DIRECCION"</span>, <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">80</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br />                           <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"POBLACION"</span>, <span style="color: #ff0000;">"C"</span>, <span style="color: #000000;">80</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span>, ;<br /> <span style="color: #00C800;">local</span> nLen := len<span style="color: #000000;">&#40;</span> aArray <span style="color: #000000;">&#41;</span><br /> <span style="color: #00C800;">local</span> i<br /><br /> <span style="color: #00C800;">for</span> n := <span style="color: #000000;">1</span> <span style="color: #0000ff;">to</span> nLen<br />      <span style="color: #00C800;">if</span> aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> == <span style="color: #ff0000;">'C'</span> .and. aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> == <span style="color: #000000;">80</span><br />            aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> := nNuevoLen <span style="color: #B900B9;">// Aquí pondrías el nuevo valor</span><br />      end <span style="color: #00C800;">if</span><br /> <span style="color: #00C800;">next</span><br /><br />...<br /> <br /> </div>[/code:3lvn10db] Espero que la idea te valga <!-- s;-) --><img src="{SMILIES_PATH}/icon_wink.gif" alt=";-)" title="Wink" /><!-- s;-) -->
duda array
Perdón la n debe ser una i [code=fw:2bc1t8tt]<div class="fw" id="{CB}" style="font-family: monospace;"><br />&nbsp;<span style="color: #00C800;">for</span> n := <span style="color: #000000;">1</span> <span style="color: #0000ff;">to</span> nLen<br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">if</span> aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> == <span style="color: #ff0000;">'C'</span> .and. aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> == <span style="color: #000000;">80</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> := nNuevoLen <span style="color: #B900B9;">// Aquí pondrías el nuevo valor</span><br />&nbsp; &nbsp; &nbsp; end <span style="color: #00C800;">if</span><br />&nbsp;<span style="color: #00C800;">next</span><br /><br />&nbsp;</div>[/code:2bc1t8tt] [code=fw:2bc1t8tt]<div class="fw" id="{CB}" style="font-family: monospace;"> <br /><span style="color: #00C800;">for</span> i := <span style="color: #000000;">1</span> <span style="color: #0000ff;">to</span> nLen<br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">if</span> aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> == <span style="color: #ff0000;">'C'</span> .and. aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> == <span style="color: #000000;">80</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; aArray<span style="color: #000000;">&#91;</span> i, <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> := nNuevoLen <span style="color: #B900B9;">// Aquí pondrías el nuevo valor</span><br />&nbsp; &nbsp; &nbsp; end <span style="color: #00C800;">if</span><br />&nbsp;<span style="color: #00C800;">next</span><br />&nbsp;</div>[/code:2bc1t8tt]
duda con ADO
que tal foro, actualmente tengo un servidor con bases de datos de SQL, mi intencion es poder leerlas, estaba pensando usar ADO, pero segun me comentaron que con ADO esas bases de datos al momento de abrirlas solo me las abriria de modo exclusivo no compartido, es cierto? o en su defecto que me recomiendan usar de acuerdo a su experiencia... salu2 Paco
duda con ADO
¿¿¿¿Pero quien te dijo esa barbaridad ????? ADO te puede abrir las tablas para lectura y escritura, compartidas o exclusivas ejecutar procesos almacenado y todo lo que puedes hacer con un SQL normal, todo depende del tipo de cursor que quieras utilizar. ADO es totalmente flexible, es mas, es una vil copia del modelo xBase pero basado en SQL.
duda con ADO
gracias rene por tu aclaracion (eso mismo pense, pero como no he usado sql ni ado tan amplio, por eso) y muy puntual como siempre. Aqui haciendo un poco de historia es lo siguiente: antes habia un sistema hecho en clipper 100% y yo hice subsistemas de esas dbf, luego los clipperos contrataron para migrar ese sistema a vb con sql, tons les comente que iba a hacer subsistemas de ese sistema, jeje, pero como que no les parecio y un programador de vb me comento eso, se me hizo raro, pero por no dejar pregunto. y alguien que use fcsodbc? alguna experiencia? gracias salu2 paco
duda con ADO
Una vez que conoces ADO no hace falta que inventes nada mas, el modelo ADO es universal, te sirve para conectar con cualquier base de datos solo camiando una linea de codigo de tu programa. Cuando tu ves como funciona ADO, te das cuenta de que el modelo XBase no esta tan obsoleto como dicen.
duda con ADO
Paquito, Paquito , no debería de ayudarte, jajajajaja, pide ayuda a la Cervecera que compró a Oswaldo y se lo llevó del Guadalajara. En fin , cosas de futbol. Cómo bien dice Rene con ADO puedes realizar cualquier conexión , actualmente estoy trabajando para que la nueva versión del producto en la empresa donde presto mis servicios, utilice cualquier motor SQL que haya en el mercado y creéme que te quedas maravillado cuando ves lo práctico que es usar ADO. No te entumas y pegame un grito.
duda con ADO
ni modo vik, asi es el futbol, ahora nos toca la de ver para arriba (eso espero) y pos salud con Victoria !!! gracias por tu ayuda, lo tendre en cuenta para cualquier consulta sin miramientos sobre ADO... gracias rene!! gracias vik!! nomas una ultima pregunta: algun lugar donde documentarme de ado, con todas las monerias que hace? salu2
duda con ADO
Francisco, [quote:3dhn3x2v]nomas una ultima pregunta: algun lugar donde documentarme de ado, con todas las monerias que hace?[/quote:3dhn3x2v] Mira a ver si tienes este fichero en tu equipo. [quote:3dhn3x2v]"C:\Archivos de programa\Archivos comunes\Microsoft Shared\OFFICE11\3082\ADO210.CHM"[/quote:3dhn3x2v] Normalmente este fichero de ayuda se instala con el office de MS. Adicionamente en mi blog ([url:3dhn3x2v]http&#58;//www&#46;capelblog&#46;com[/url:3dhn3x2v]) puedes encontrar un artículo donde indico bibliografía. Saludos, José Luis Capel
duda con ADO
gracias jose luis, <!-- s;-) --><img src="{SMILIES_PATH}/icon_wink.gif" alt=";-)" title="Wink" /><!-- s;-) --> salu2 paco
duda con AdsEnableEncryption
Hola, estoy pasando mis bases de datos DBF/CDX al RDD de ADS en forma local y la idea es utilizar la funcion AdsEnableEncryption y me surgio la siguiente duda, es posible determinar si una DBF ya está encriptada? digamos quiero hacer algo asi Use Database Shared New if .not. DBFencryp AdsEnableEncryption("passw") AdsEncryptTable() else AdsEnableEncryption("passw") endif gracias
duda con AdsEnableEncryption
Estoy intentando como tu probar a migrar a ADS pero tengo algunos problemas. Me gustaria comentar contigo por mail privado. Mi mail es <!-- e --><a href="mailto:watchdog@telefonica.net">watchdog@telefonica.net</a><!-- e --> Gracias. Manuel Calero Solís.