topic
stringlengths
1
63
text
stringlengths
1
577k
problem with gdiplus
[b:1p119b5g]with xharbour[/b:1p119b5g] [code=fw:1p119b5g]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Harbour</span>.Exe Lib\tgdiplus.prg &nbsp;/m /n0 /gc1 /es2 /a /iC:\Work\fwh\include;C:\work\bcc7\Include\dinkumware /iC:\work\XHARBOUR\Include /jD:\VERSIONI\STAR_R~<span style="color: #000000;">1</span>\I18n\Main.hil /iinclude;c:\work\fwh\include;C:\work\XHARBOUR\include /oObj\tgdiplus.c<br />xHarbour <span style="color: #000000;">1.2</span><span style="color: #000000;">.3</span> Intl. <span style="color: #000000;">&#40;</span>SimpLex<span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#40;</span>Build <span style="color: #000000;">20140725</span><span style="color: #000000;">&#41;</span><br />Copyright <span style="color: #000000;">1999</span><span style="color: #000000;">-2014</span>, http:<span style="color: #B900B9;">//www.xharbour.org <!-- m --><a class="postlink" href="http://www.harbour-project.org/">http://www.harbour-project.org/</a><!-- m --></span><br />Compiling <span style="color: #ff0000;">'Lib<span style="color: #000000;">\t</span>gdiplus.prg'</span>...<br />Generating international list <span style="color: #0000ff;">to</span> <span style="color: #ff0000;">'D:<span style="color: #000000;">\V</span>ERSIONI<span style="color: #000000;">\S</span>TAR_R~1<span style="color: #000000;">\I</span>18n<span style="color: #000000;">\M</span>ain.hil'</span>...<br />Generating C source output <span style="color: #0000ff;">to</span> <span style="color: #ff0000;">'Obj<span style="color: #000000;">\t</span>gdiplus.c'</span>...<br />Done.<br />Lines <span style="color: #000000;">792</span>, Functions/Procedures <span style="color: #000000;">39</span>, pCodes <span style="color: #000000;">2858</span><br /><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Bcc32</span>.Exe -M -c -DHB_OS_WIN_32 -DHB_FM_STATISTICS_OFF -DHB_NO_DEFAULT_API_MACROS -DHB_NO_DEFAULT_STACK_MACROS -IC:\Work\fwh\include;C:\work\bcc7\Include\dinkumware -IC:\work\bcc7\Include\windows\sdk\;C:\work\XHARBOUR\Include &nbsp;-nD:\VERSIONI\STAR_R~<span style="color: #000000;">1</span>\Obj tgdiplus.c<br />Embarcadero C++ <span style="color: #000000;">7.00</span> <span style="color: #00C800;">for</span> Win32 Copyright <span style="color: #000000;">&#40;</span>c<span style="color: #000000;">&#41;</span> <span style="color: #000000;">1993</span><span style="color: #000000;">-2015</span> Embarcadero Technologies, Inc.<br />tgdiplus.c:<br /><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">PORC</span>.EXE <span style="color: #0000ff;">Resource</span>\vai.rc &nbsp;/I c:\work\pellesc\include /I c:\work\pellesc\include\win<br /><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">iLink32</span>.Exe -Gn -aa -Tpe -s -v @TEST.bcl<br />Turbo Incremental Link <span style="color: #000000;">6.70</span> Copyright <span style="color: #000000;">&#40;</span>c<span style="color: #000000;">&#41;</span> <span style="color: #000000;">1997</span><span style="color: #000000;">-2014</span> Embarcadero Technologies, Inc.<br />Error: <span style="color: #000000;">Unresolved</span> external <span style="color: #ff0000;">'_hb_partdt'</span> referenced <span style="color: #0000ff;">from</span> C:\WORK\FWH\LIB\FIVEHX.LIB|VALTOSTT<br />Error: <span style="color: #000000;">Unable</span> <span style="color: #0000ff;">to</span> perform link<br />&nbsp;</div>[/code:1p119b5g] [b:1p119b5g]with harbour [/b:1p119b5g] [code=fw:1p119b5g]<div class="fw" id="{CB}" style="font-family: monospace;">Progetto: <span style="color: #000000;">TEST</span>, Ambiente: <span style="color: #000000;">bcc7Harbor</span>:<br /><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Harbour</span>.Exe Source\TEST.PRG &nbsp;/m /n0 /gc1 /es2 /a /iC:\Work\fwh\include;C:\work\bcc7\Include\dinkumware /iC:\work\HARBOUR\Include /jD:\VERSIONI\STAR_R~<span style="color: #000000;">1</span>\I18n\Main.hil /iinclude;c:\work\fwh\include;C:\work\HARBOUR\include /oObj\TEST.c<br />Harbour <span style="color: #000000;">3.2</span>.0dev <span style="color: #000000;">&#40;</span>r1703231115<span style="color: #000000;">&#41;</span><br />Copyright <span style="color: #000000;">&#40;</span>c<span style="color: #000000;">&#41;</span> <span style="color: #000000;">1999</span><span style="color: #000000;">-2016</span>, http:<span style="color: #B900B9;">//harbour-project.org/</span><br />Compiling <span style="color: #ff0000;">'Source<span style="color: #000000;">\T</span>EST.PRG'</span>...<br />Lines <span style="color: #000000;">5013</span>, Functions/Procedures <span style="color: #000000;">5</span><br />Generating C source output <span style="color: #0000ff;">to</span> <span style="color: #ff0000;">'Obj<span style="color: #000000;">\T</span>EST.c'</span>... Done.<br /><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Bcc32</span>.Exe -M -c -DHB_OS_WIN_32 -DHB_FM_STATISTICS_OFF -DHB_NO_DEFAULT_API_MACROS -DHB_NO_DEFAULT_STACK_MACROS -IC:\Work\fwh\include;C:\work\bcc7\Include\dinkumware -IC:\work\bcc7\Include\windows\sdk\;C:\work\HARBOUR\Include &nbsp;-nD:\VERSIONI\STAR_R~<span style="color: #000000;">1</span>\Obj TEST.c<br />Embarcadero C++ <span style="color: #000000;">7.00</span> <span style="color: #00C800;">for</span> Win32 Copyright <span style="color: #000000;">&#40;</span>c<span style="color: #000000;">&#41;</span> <span style="color: #000000;">1993</span><span style="color: #000000;">-2015</span> Embarcadero Technologies, Inc.<br />TEST.c:<br /><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">Bcc32</span>.Exe -M -c -DHB_OS_WIN_32 -DHB_FM_STATISTICS_OFF -DHB_NO_DEFAULT_API_MACROS -DHB_NO_DEFAULT_STACK_MACROS -IC:\Work\fwh\include;C:\work\bcc7\Include\dinkumware -IC:\work\bcc7\Include\windows\sdk\;C:\work\HARBOUR\Include &nbsp;-nD:\VERSIONI\STAR_R~<span style="color: #000000;">1</span>\Obj gdiplus.cpp<br />Embarcadero C++ <span style="color: #000000;">7.00</span> <span style="color: #00C800;">for</span> Win32 Copyright <span style="color: #000000;">&#40;</span>c<span style="color: #000000;">&#41;</span> <span style="color: #000000;">1993</span><span style="color: #000000;">-2015</span> Embarcadero Technologies, Inc.<br />gdiplus.cpp:<br /><span style="color: #000000;">Warning</span> W8022 C:\work\bcc7\Include\windows\sdk\GdiplusHeaders.h <span style="color: #000000;">636</span>: <span style="color: #ff0000;">'Bitmap::Clone(const Rect &,int)'</span> hides virtual <span style="color: #00C800;">function</span> <span style="color: #ff0000;">'Image::Clone()'</span><br />Warning W8004 gdiplus.cpp <span style="color: #000000;">65</span>: <span style="color: #ff0000;">'graphics'</span> is assigned a value that is never used in <span style="color: #00C800;">function</span> HB_FUN_GDIPLUSGRAPHICSFROMIMG<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />Error E2227 gdiplus.cpp <span style="color: #000000;">2103</span>: <span style="color: #000000;">Extra</span> parameter in call <span style="color: #0000ff;">to</span> hb_parl<span style="color: #000000;">&#40;</span>int<span style="color: #000000;">&#41;</span> in <span style="color: #00C800;">function</span> HB_FUN_GDIPONOFFARRAY<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />Error E2227 gdiplus.cpp <span style="color: #000000;">2126</span>: <span style="color: #000000;">Extra</span> parameter in call <span style="color: #0000ff;">to</span> hb_parl<span style="color: #000000;">&#40;</span>int<span style="color: #000000;">&#41;</span> in <span style="color: #00C800;">function</span> HB_FUN_GDIPONOFFARRAY<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />*** <span style="color: #000000;">2</span> errors in Compile ***<br />&nbsp;</div>[/code:1p119b5g]
problem with gdiplus
[quote="Silvio.Falconi":3s8naay1][b:3s8naay1]with xharbour[/b:3s8naay1] [code=fw:3s8naay1]<div class="fw" id="{CB}" style="font-family: monospace;">xHarbour <span style="color: #000000;">1.2</span><span style="color: #000000;">.3</span> Intl. <span style="color: #000000;">&#40;</span>SimpLex<span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#40;</span>Build <span style="color: #000000;">20140725</span><span style="color: #000000;">&#41;</span></div>[/code:3s8naay1][/quote:3s8naay1] hb_partdt() is in xHarbour since 2015. You xHarbour is too old (2014). EMG
problem with gdiplus
sorry I was interested in harbour. I did a test with xharbour to see if it was compiled with respect to harbour
problem with get
why the variable cNR in GET is not equal to the variable which return function daj_nr() DEFINE DIALOG oDlg FROM 0,0 to 180*2.05,200*2.05 PIXEL ; TITLE If( lAppend, "Nowy", "Modyfikacja" ) FONT oFont k1:=10 k2:=50 mn:=2.05 @ 10, k1 SAY "&Typ:" OF oDlg PIXEL @ 10, k2 GET cTyp picture '!' when lAppend valid(eval({|| cNR:=daj_nr(cTYP), cTYP $ 'S_W'})) OF oDlg SIZE 10,12 PIXEL @ 25, k1 SAY "&Nr:" OF oDlg PIXEL @ 25, k2 GET cNr picture '99999' when lAppend OF oDlg PIXEL @ 40, k1 SAY "&Nazwa:" OF oDlg PIXEL @ 40, k2 GET cNazwa picture replicate('!',40) OF oDlg PIXEL @ 55, k1 SAY "&Opis:" OF oDlg PIXEL @ 55, k2 GET cOpis picture replicate('!',40) OF oDlg PIXEL @ 70, k1 SAY "&Nr ew:" OF oDlg PIXEL @ 70, k2 GET cNr_ew picture 'XXXXXXXXXXXXXXX' OF oDlg PIXEL @ 85, k1 SAY "&Nr zak:" OF oDlg PIXEL @ 85, k2 GET cNr_zak picture '99999' OF oDlg PIXEL @100, k1 SAY "&U&#380;ytkownik:" OF oDlg PIXEL @100, k2 GET cUZYTKOW picture replicate('!',40) OF oDlg PIXEL @115, k1 SAY "&Ilo&#347;&#263;:" OF oDlg PIXEL @115, k2 GET cIlosc_sk picture '999' OF oDlg PIXEL @130, k1 SAY "&Cena:" OF oDlg PIXEL @130, k2 GET cCena picture '999,999,999.99' OF oDlg PIXEL @160, 60 BUTTON "&Rezygnacja" OF oDlg SIZE 50, 12 PIXEL ACTION oDlg:End() @160, 120 BUTTON "&Zapis" OF oDlg SIZE 50, 12 PIXEL ACTION ( lSave := .T., oDlg:End() ) ACTIVATE DIALOG oDlg CENTER //----------------------------------------------------------------------------//static function daj_nr(cTYP) local NR_:=0 dbsetorder(1) dbseek(cTYP,.f.,.t.) NR_:=nr+1return NR_//---------------------------------------------------------------------------//
problem with get
kajot,please, try like this[code:29cnbpbe] &#46;&#46;&#46; &#46;&#46;&#46; @ 10, k2 GET oTyp picture '@!'; when lAppend; valid if&#40; cTyp $ "S_W",; &#40; cNr &#58;= daj_nr&#40; cTYP &#41;, oNr&#58;Refresh&#40;&#41;, &#46;t&#46; &#41;,; &#46;f&#46; &#41; OF oDlg SIZE 10,12 PIXEL @ 25, k1 SAY "&Nr&#58;" OF oDlg PIXEL @ 25, k2 GET oNr VAR cNr picture '99999' when lAppend OF oDlg PIXEL &#46;&#46;&#46; &#46;&#46;&#46; [/code:29cnbpbe]regards,Detlef
problem with get
Thanks, is OK
problem with harbour dll
Hello, I am doing some test to use dynamic dll in harbour inside my code. I see that to allow the dynamic loading of harbour module I need to build the application with the [b:1twttnuo]-shared[/b:1twttnuo] hbmk2 option active, But when I try I obtain: [code=fw:1twttnuo]<div class="fw" id="{CB}" style="font-family: monospace;">FiveHC32.lib<span style="color: #000000;">&#40;</span>ACTX.obj<span style="color: #000000;">&#41;</span> : <span style="color: #000000;">error</span> LNK2019: <span style="color: #000000;">riferimento</span> al simbolo esterno _hb_gcGripGet non risolto nella funzione _HB_FUN_CREATEACTIVEX<br />FiveHC32.lib<span style="color: #000000;">&#40;</span>ACTX.obj<span style="color: #000000;">&#41;</span> : <span style="color: #000000;">error</span> LNK2019: <span style="color: #000000;">riferimento</span> al simbolo esterno _hb_gcGripDrop non risolto nella funzione _HB_FUN_ACTXEND<br />&nbsp;</div>[/code:1twttnuo] any hint?
problem with harbour dll
Antonino, Those symbols are exported in hbvm.lib so it is strange that you get that Could you provide a self contained example to try ?
problem with harbour dll
The error is present even with a simple code like: [code=fw:28liv3a4]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <fivewin.ch><br /><br />proc main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />    <span style="color: #00C800;">local</span> i:=<span style="color: #000000;">1</span></div>[/code:28liv3a4] usually I compile them with hbmk2, with this command line [code=fw:28liv3a4]<div class="fw" id="{CB}" style="font-family: monospace;">hbmk2 main.prg -Lc:\fwh\lib -Ic:\fwh\include -lfiveh32 -lfivehc32 hbct.hbc xhb.hbc hbmzip.hbc -gui hbziparc.hbc -lversion -lgdiplus -loledlg -ldflag=/NODEFAULTLIB:<span style="color: #000000;">libcmt</span></div>[/code:28liv3a4] If I add [b:28liv3a4]-shared[/b:28liv3a4] the error appears. If I try adding trace, I see that the link part changes considerably. without shared [quote:28liv3a4]-nologo -out:main.exe C:\Users\iorpe\AppData\Local\Temp\hbmk_8ahefq.dir\main.obj -libpath:c:\Harbour32\lib\win\msvc -libpath:c:\fwh\lib /NODEFAULTLIB:libcmt -subsystem:windows fiveh32.lib fivehc32.lib hbct.lib xhb.lib hbtip.lib hbfship.lib hbxpp.lib hbwin.lib png.lib hbmzip.lib minizip.lib hbziparc.lib version.lib gdiplus.lib oledlg.lib [b:28liv3a4]hbextern.lib[/b:28liv3a4] hbdebug.lib [b:28liv3a4]hbvm.lib hbrtl.lib hblang.lib hbcpage.lib gtcgi.lib gtpca.lib gtstd.lib gtwin.lib gtwvt.lib gtgui.lib hbrdd.lib hbuddall.lib hbusrrdd.lib rddntx.lib rddcdx.lib rddnsx.lib rddfpt.lib hbrdd.lib hbhsx.lib hbsix.lib hbmacro.lib [/b:28liv3a4]hbcplr.lib[b:28liv3a4] hbpp.lib hbcommon.lib[/b:28liv3a4] winmm.lib kernel32.lib user32.lib gdi32.lib advapi32.lib ws2_32.lib iphlpapi.lib winspool.lib comctl32.lib comdlg32.lib shell32.lib uuid.lib ole32.lib oleaut32.lib mpr.lib mapi32.lib imm32.lib msimg32.lib wininet.lib [b:28liv3a4]hbpcre.lib hbzlib.lib[/b:28liv3a4][/quote:28liv3a4] with shared [quote:28liv3a4]-nologo -out:main.exe C:\Users\iorpe\AppData\Local\Temp\hbmk_bhxtdw.dir\main.obj -libpath:c:\Harbour32\lib\win\msvc -libpath:c:\fwh\lib /NODEFAULTLIB:libcmt -subsystem:windows fiveh32.lib fivehc32.lib hbct.lib xhb.lib hbtip.lib hbfship.lib hbxpp.lib hbwin.lib png.lib hbmzip.lib minizip.lib hbziparc.lib version.lib gdiplus.lib oledlg.lib [b:28liv3a4]hbmainstd.lib hbmainwin.lib[/b:28liv3a4] hbcplr.lib hbdebug.lib winmm.lib kernel32.lib user32.lib gdi32.lib advapi32.lib ws2_32.lib iphlpapi.lib winspool.lib comctl32.lib comdlg32.lib shell32.lib uuid.lib ole32.lib oleaut32.lib mpr.lib mapi32.lib imm32.lib msimg32.lib wininet.lib [b:28liv3a4]"harbour-32.lib"[/b:28liv3a4][/quote:28liv3a4]
problem with harbour dll
I created a more complete sample. dll.prg [code=fw:u7tv3q2g]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <fivewin.ch><br />DYNAMIC FW_GT<br /><br />DYNAMIC <span style="color: #0000ff;">MsgInfo</span><br />DYNAMIC TWindow<br />DYNAMIC TSay<br /><br />proc Function1<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Hello from Dll1"</span><span style="color: #000000;">&#41;</span><br /><br />proc Function2<span style="color: #000000;">&#40;</span>oParent<span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">LOCAL</span> oWnd, oSay<br />   <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">WINDOW</span> oWnd <span style="color: #0000ff;">OF</span> oParent<br />   @ <span style="color: #000000;">1</span>,<span style="color: #000000;">1</span> <span style="color: #0000ff;">SAY</span> oSay <span style="color: #0000ff;">PROMPT</span> <span style="color: #ff0000;">"Hello from Dll2"</span><br />   <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> oWnd</div>[/code:u7tv3q2g] main.prg [code=fw:u7tv3q2g]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00D7D7;">#include</span> <fivewin.ch><br /><br />DYNAMIC Function1<br />DYNAMIC Function2<br /><br />proc main<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">LOCAL</span> oWnd, pDll<br />   CoInitialize<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   pDll := HB_LibLoad<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"dll.dll"</span> <span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">WINDOW</span> oWnd <br />   @ <span style="color: #000000;">1</span>,<span style="color: #000000;">1</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #ff0000;">"Test1"</span> <span style="color: #0000ff;">ACTION</span> iif<span style="color: #000000;">&#40;</span>type<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Function1()"</span><span style="color: #000000;">&#41;</span>==<span style="color: #ff0000;">"UI"</span>,Function1<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>,<span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Function1 not found"</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />   @ <span style="color: #000000;">3</span>,<span style="color: #000000;">1</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #ff0000;">"Test2"</span> <span style="color: #0000ff;">ACTION</span> iif<span style="color: #000000;">&#40;</span>type<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Function2()"</span><span style="color: #000000;">&#41;</span>==<span style="color: #ff0000;">"UI"</span>,Function2<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>,<span style="color: #0000ff;">MsgInfo</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Function2 not found"</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> oWnd</div>[/code:u7tv3q2g] then build them with [code=bat:u7tv3q2g]<div id="{CB}" style="font-family: monospace;">set FWH_INSTALL=c:\fwh32<br />hbmk2  dll.prg -i${FWH_INSTALL}\include -hbdynvm -shared -inc<br />hbmk2  main.prg -hbexe -gui -i${FWH_INSTALL}\include -L${FWH_INSTALL}\lib -lFiveH32 -lFiveHC32 -lVersion -lOleDlg -lGdiplus -ldflag=/NODEFAULTLIB:libcmt xhb.hbc hbziparc.hbc -shared -ldflag=/force -inc</div>[/code:u7tv3q2g] It works, but the output contains: [code=dos:u7tv3q2g]<div class="dos" id="{CB}" style="font-family: monospace;">hbmk2: Link <a href="http://www.ss64.com/nt/in.html"><span style="color: #00b100; font-weight: bold;">in</span></a> corso di... main.exe<br />FiveHC32.lib<span style="color: #66cc66;">&#40;</span>ACTX.obj<span style="color: #66cc66;">&#41;</span> : <span style="color: #b100b1; font-weight: bold;">error LNK2019: unresolved external symbol _hb_gcGripGet referenced <a href="http://www.ss64.com/nt/in.html"><span style="color: #00b100; font-weight: bold;">in</span></a> function _HB_FUN_CREATEACTIVEX</span><br />FiveHC32.lib<span style="color: #66cc66;">&#40;</span>ACTX.obj<span style="color: #66cc66;">&#41;</span> : <span style="color: #b100b1; font-weight: bold;">error LNK2019: unresolved external symbol _hb_gcGripDrop referenced <a href="http://www.ss64.com/nt/in.html"><span style="color: #00b100; font-weight: bold;">in</span></a> function _HB_FUN_ACTXEND</span><br />main.exe : <span style="color: #b100b1; font-weight: bold;">warning LNK4088: image being generated due to /force option image may <a href="http://www.ss64.com/nt/not.html"><span style="color: #000000; font-weight: bold;">not</span></a> run</span></div>[/code:u7tv3q2g]
problem with harbour dll
What I want to do was already treaty [url:dndk66fu]http&#58;//forums&#46;fivetechsupport&#46;com/viewtopic&#46;php?f=3&t=23372[/url:dndk66fu] and in other Spanish threads, that I don't understand
problem with hbzip
Any I dea ? Turbo Incremental Link 5.69 Copyright (c) 1997-2005 Borland Error: Unresolved external '_inflateEnd' referenced from C:\WORK\XHARBOUR\LIB\HBZIP.LIB|ziparchive Error: Unresolved external '_deflate' referenced from C:\WORK\XHARBOUR\LIB\HBZIP.LIB|ziparchive Error: Unresolved external '_get_crc_table' referenced from C:\WORK\XHARBOUR\LIB\HBZIP.LIB|ziparchive Error: Unresolved external '_deflateEnd' referenced from C:\WORK\XHARBOUR\LIB\HBZIP.LIB|ziparchive Error: Unresolved external '_deflateInit2_' referenced from C:\WORK\XHARBOUR\LIB\HBZIP.LIB|ziparchive Error: Unresolved external '_crc32' referenced from C:\WORK\XHARBOUR\LIB\HBZIP.LIB|ziparchive Error: Unresolved external '_inflateInit2_' referenced from C:\WORK\XHARBOUR\LIB\HBZIP.LIB|ziparchive Error: Unresolved external '_inflate' referenced from C:\WORK\XHARBOUR\LIB\HBZIP.LIB|ziparchive
problem with hbzip
To use Zip & Unzip functions in xHarbour you have to link hbzip.lib and zlib.lib Both the lib files are available in your \xHarbour\Lib folder Regards [b:3rv9vmzh]Anser[/b:3rv9vmzh]
problem with hbzip
I insert hbzip and zlib on my compile lnk from two years, the question was logic for me ... I allready insert these libs to compile the app..
problem with incremental search in xbrowse
[img:1xrcszwe]https&#58;//gifup&#46;com/data/gifs/5/2/6/5267a23ea7&#46;gif[/img:1xrcszwe] if my criteria searched is founded , the filter is ok , but if the criteria given no longer exist then my filter developes in blank why happens that? i use fwh 13.01, could be that the problem? my source code [code=fw:1xrcszwe]<div class="fw" id="{CB}" style="font-family: monospace;"><br />        oRs := TOleAuto<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: #ff0000;">"ADODB.RecordSet"</span> <span style="color: #000000;">&#41;</span><br />        WITH OBJECT oRs<br />          :<span style="color: #000000;">ActiveConnection</span> := oConnect<br />          :<span style="color: #000000;">Source</span>             := <span style="color: #ff0000;">"SELECT Ruc,Ng,Di,Lo,Nf,Lf,Directi,codubi,TipIde,De, ubigeo,Dpto,Prov, Distri,Urb,Email,Te,modo, Codigo from Mcodi where codusu = '"</span>+cUsuCod+<span style="color: #ff0000;">"'"</span><br />          :<span style="color: #000000;">CursorLocation</span>     := adUseClient<br />          :<span style="color: #000000;">CursorType</span>         := adOpenStatic<br />          :<span style="color: #000000;">LockType</span>           := adLockOptimistic<br />          :<span style="color: #000000;">Open</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />        END<br />   <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"TAHOMA"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>,<span style="color: #000000;">-12</span><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;">750</span>,<span style="color: #000000;">300</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />      <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"XBrowse Incremental Filters"</span><br /><br />            @ <span style="color: #000000;">30</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">XBROWSE</span> oBrw <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">-10</span>,<span style="color: #000000;">-10</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />            DATASOURCE oRs                                  ;<br />            COLUMNS <span style="color: #ff0000;">"Codigo"</span>,<span style="color: #ff0000;">"Ng"</span>,<span style="color: #ff0000;">"RUC"</span>,<span style="color: #ff0000;">"Te"</span>,<span style="color: #ff0000;">"Di"</span>,<span style="color: #ff0000;">"Lo"</span>,<span style="color: #ff0000;">"Nf"</span>  ;<br />            HEADERS <span style="color: #ff0000;">"CODIGO"</span>                                 ;<br />                  ,<span style="color: #ff0000;">"RAZÓN SOCIAL"</span>                  ;<br />                  ,<span style="color: #ff0000;">"NO. IDENT."</span>                    ;<br />                  ,<span style="color: #ff0000;">"TELÉFONOS"</span>                     ;<br />                  ,<span style="color: #ff0000;">"DIRECCIÓN"</span>                     ;<br />                  ,<span style="color: #ff0000;">"LOCALIDAD"</span>                     ;<br />                  ,<span style="color: #ff0000;">"DIR.ENT."</span>                      ;<br />                  AUTOSORT CELL LINES NOBORDER<br />            oBrw:<span style="color: #000000;">lIncrFilter</span> := .t.<br />            oBrw:<span style="color: #000000;">lSeekWild</span> := .t.<br />            oBrw:<span style="color: #000000;">cFilterFld</span> := <span style="color: #ff0000;">"NG"</span><br />            oBrw:<span style="color: #000000;">nStretchCol</span>   := STRETCHCOL_WIDEST<br /><br />   @ <span style="color: #000000;">11</span>,<span style="color: #000000;">160</span> <span style="color: #0000ff;">SAY</span> oBrw:<span style="color: #000000;">oSeek</span> <span style="color: #0000ff;">PROMPT</span> oBrw:<span style="color: #000000;">cSeek</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">200</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">PIXEL</span> ;<br />      <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">COLOR</span> CLR_BLACK,CLR_YELLOW <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">'@!'</span>                 <br />   oBrw:<span style="color: #000000;">CreateFromCode</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTERED</span> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">INIT</span> <span style="color: #000000;">&#40;</span> oBrw:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, .f. <span style="color: #000000;">&#41;</span><br /><br /> </div>[/code:1xrcszwe] link of the source code xbrowse.prg <!-- m --><a class="postlink" href="https://www.dropbox.com/s/2gpxi1mxfayo4ax/xbrowse.prg?dl=0">https://www.dropbox.com/s/2gpxi1mxfayo4 ... e.prg?dl=0</a><!-- m --> thanks in advance
problem with label class
when I preview label run ok then I close label preview it make error Called from: Lib\LABEL\PDLABEL.PRG => LBLEND(77)
problem with mciSendStr()
To play a video containing both moving picture and sound, I use the mci code below. If I run the program in XP it works fine - the sound is heard and the moving picture is displayed. But if I run it in Vista Home Premium, the sound is heard but the moving picture is not displayed.What am I doing wrong?- Roger[code:2jmu5uqf] STATIC FUNCTION VidPlay&#40;oDlg,cBuffer,oBmp3,cFileV&#41; LOCAL nStart &#58;= 0 cBuffer&#58;=Space&#40;200&#41; IF EMPTY&#40;cFileV&#41; cFileV &#58;= "MyVideo&#46;avi" ENDIF mciSendStr&#40;"OPEN AVIVIDEO!"+Upper&#40;Alltrim&#40;cFileV&#41;&#41;+" ALIAS VIDEO PARENT "; +Alltrim&#40;str&#40;oBmp3&#58;hWnd&#41;&#41;,@cBuffer,oDlg&#58;hWnd&#41; mciSendStr&#40;"put video destination at 0 0 220 174",@cBuffer,oDlg&#58;hWnd&#41; mciSendStr&#40;"WINDOW VIDEO HANDLE "+Alltrim&#40;str&#40;oBmp3&#58;hWnd&#41;&#41;,@cBuffer,oDlg&#58;hWnd&#41; mciSendStr&#40;"PLAY VIDEO FROM "+ALLTRIM&#40;STR&#40;nStart&#41;&#41;,@cBuffer,oDlg&#58;hWnd&#41; RETURN nil [/code:2jmu5uqf]
problem with mciSendStr()
Roger,It could be a missing AVI required codec in Vista.Are you able to properly play the AVI from the Media Player ?
problem with mciSendStr()
Antonio,Your suggestion pointed me in the right direction, but there is still a problem.If I play my video Harry.avi or Shuttle3.avi on my Vista computer's Windows Media Player, again only the sound plays with no picture. But if I play Sample.avi (provided by Microsoft with Win '95) on the Vista Win Media Player, then I get BOTH sound and picture. Then, if I play Sample.avi on Vista in my FWH/xHb app, I also get both sound and picture. So it seems to not be an FWH/xHb problem. As I mentioned earlier, Harry.avi and Shuttle3.avi play with both picture and sound in XP and Win '98. So it seems that Vista doesn't like some kinds of .avi files. I've uploaded both Shuttle3.avi (works only on XP) and Sample.avi (works on both XP and Vista) to the URLs below in case you care to look at them and see if you can see some technical difference in them. If so, it would be useful to all of us to know this difference. Each file is under 2 MB in size.[/url]http://www.leadersoft.com/files/Sample.avi[url][/url]http://www.leadersoft.com/files/Shuttle3.avi[url]Thanks for your help,- Roger[/url]
problem with mciSendStr()
Well, now I'm learning about codec files - what a mess!Oh for the good old days when IBM ruled the roost and everything was perfect. <!-- s;-) --><img src="{SMILIES_PATH}/icon_wink.gif" alt=";-)" title="Wink" /><!-- s;-) -->
problem with mciSendStr()
Roger,Yes, I agree, codecs are a real mess <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
problem with mciSendStr()
For anyone else who is working with AVI video and who might be interested in the solution that I found to this problem, here it is...My original video had been edited and output to AVI using Pinnacle Studio 7. In outputing to AVI, I had originally used the Intel Indeo R3.2 codec compression tool. (A codec is a dll that compresses the video into a much more compact disk space than the "raw" avi, taking a 100 mb "raw" avi and squeezing it down to less than 10 mb in a compressed avi.) My output AVI could be displayed okay on Windows 95, 98, 2000 and XP, but on Vista the audio could be heard but the video picture did not appear. Curiously, I found that the codec file for Indeo R3.2 does in fact exist in the Win Vista system32 folder, but for some unknown reason wouldn't show the moving image part of the video. So I went back to Studio 7 and experimented with other codecs (different methods of video compression). The only codec supplied with Studio 7 that works on Vista (showing the moving picture) is Cinepak Codek by Radius - which is also supplied by default with Win Vista. Its compression is not as tight as Indeo R3.2, but at least it works on Vista as well as XP.If one upgrades to Pinnacle Studio 12, there are apparently more codecs included that are compatible with Vista, and which may offer greater compression than Cinepak.- Roger
problem with mysql
source#include "adordd.ch"#include "FiveWin.ch"REQUEST ADORDDfunction Main() USE inkom VIA "ADORDD" TABLE "KASA" MYSQL ; FROM "localhost" USER "root" PASSWORD "root" Browse() USEreturn nil error.logApplication=========== Path and name: D:\FWH\prg\mysql1\t.exe (32 bits) Size: 1,657,344 bytes Time from start: 0 hours 0 mins 0 secs Error occurred at: 10/19/08, 10:38:16 Error description: Error ADODB.Connection/0 S_OK: OPEN Args: [ 1] = C DRIVER={MySQL ODBC 3.51 Driver};server=localhost;database=inkom;uid=root;pwd=rootStack Calls=========== Called from: D:\xHarbour\source\rtl\win32ole.prg => TOLEAUTO:OPEN(0) Called from: D:\xHarbour\source\rdd\usrrdd\rdds\adordd.prg => ADO_OPEN(337) Called from: => DBUSEAREA(0) Called from: t.prg => MAIN(9)System====== CPU type: 2200 Mhz Hardware memory: 2046 megs Free System resources: 90 % GDI resources: 90 % User resources: 90 % Compiler version: xHarbour build 1.1.0 Intl. (SimpLex) (Rev. 6220) Windows version: 6.0, Build 6001 Service Pack 1 Windows total applications running: 0Variables in use================ Procedure Type Value ========================== TOLEAUTO:OPEN Param 1: C "DRIVER={MySQL ODBC 3.51 Driver};server=localhost;database=inkom;uid=root;pwd=root" Local 1: U Local 2: N 0 ADO_OPEN Param 1: N 1 Param 2: A Len: 8 Local 1: A Len: 17 Local 2: C "inkom" Local 3: U Local 4: U Local 5: U Local 6: U Local 7: U Local 8: U DBUSEAREA Param 1: L .F. Param 2: C "ADORDD" Param 3: C "inkom" Param 4: U Param 5: U Param 6: L .F. MAINLinked RDDs=========== DBF DBFFPT DBFNTX DBFBLOB ADORDDDataBases in use================Classes in use:=============== 1 HASHENTRY 2 HBCLASS 3 TOLEAUTO 4 ERROR 5 HBOBJECT 6 TREG32Memory Analysis=============== 120 Static variables Dynamic memory consume: Actual Value: 0 bytes Highest Value: 0 bytes
problem with mysql
Kajot2 things to consider...1.-Do you have the MySQL ODBC 3.51 Driver Client Installed ?2.-Do you have a personalfirewall of any kind, is Port 3306 open?Check and tell us..From ChileAdolfo
problem with mysql
1. I have MySql ODBC 3.51 installed2. port 3306 is free3. MySql Administrator works fine.
problem with mysql
hi kajot : Any feedback about your problem ? Same problem for me . Thank you. -- Best Regards -------------------------------------------------------------- kokoo KAO
problem with polish chars in print
in msginfo polish chars are ok but in object print oPrn I don't have polish chars ( in view ) my source: #include "Fivewin.ch" REQUEST HB_LANG_PL852 REQUEST HB_LANG_PLMAZ REQUEST HB_LANG_PLISO REQUEST HB_LANG_PLWIN REQUEST HB_CODEPAGE_PLMAZ REQUEST HB_CODEPAGE_PLISO REQUEST HB_CODEPAGE_PL852 REQUEST HB_CODEPAGE_PLWIN FUNCTION MAIN() LOCAL oWnd, oMenu HB_LANGSELECT( "PLWIN" ) HB_SETCODEPAGE( "PLWIN" ) // HB_SETKEYCP("PLMAZ",INIT_CP) // HB_SETDISPCP(INIT_CP,'PLMAZ',.t.) MENU oMenu MENUITEM "&Test" MENU MENUITEM "&Test1"; ACTION test1() MENUITEM "&Test2"; ACTION MSGINFO( "Test z j&#281;zyka polskiego (&#261;&#263;&#281;&#322;&#324;ó&#378;&#380;&#260;&#262;&#280;&#321;&#323;Ó&#377;&#379;)" ) ENDMENU ENDMENU DEFINE WINDOW oWnd; MENU oMenu ACTIVATE WINDOW oWnd ; ON INIT oWnd:Center() function test1() PRINT oPrn PREVIEW PAGE oPrn:Say( 2, 2, "Test z j&#281;zyka polskiego (&#261;&#263;&#281;&#322;&#324;ó&#378;&#380;&#260;&#262;&#280;&#321;&#323;Ó&#377;&#379;" ) ENDPAGE ENDPRINT return nil
problem with polish chars in print
You may need to implement a function of your own to properly convert the chars into the right ones: oPrn:Say( 2, 2, [color=red:4gmhj2zi]FixText[/color:4gmhj2zi]( "Test z j&#281;zyka polskiego (&#261;&#263;&#281;&#322;&#324;ó&#378;&#380;&#260;&#262;&#280;&#321;&#323;Ó&#377;&#379;" ) )
problem with polish chars in print
where is the function FixText ?
problem with polish chars in print
I looked formy mistake function test1() PRINT oPrn PREVIEW DEFINE FONT oFnt NAME "Arial CE" SIZE 0, -10 OF oPrn PAGE oPrn:Say( 2, 2, "Test z j&#281;zyka polskiego (&#261;&#263;&#281;&#322;&#324;ó&#378;&#380;&#260;&#262;&#280;&#321;&#323;Ó&#377;&#379;)",oFnt ) ENDPAGE ENDPRINT return nil
problem with polish chars in print
Is it working fine now ?
problem with printing
when I preview the printing I receive this error message Error (6) deleting enhanced metafile Error description FIVEWIN version 2.7 xHarbour Compiler build 0.99.51 (SimpLex) bcc No problem with fivewin 2.5
problem with printing
Patrick, Please check that you are doing a oReport:End() just once. That error usually appears when more than once the report is End()ed.
problem with printing
Antonio, Thank you fix now with your suggestion. I use to finish report with ENDPAGE ENDPRINT IF I comment out ENDPAGE, no error. I confirm that this does not occur since FWH 2.1
problem with pushbutton
Hello, I am having a problem with pushbutton. The user must click the button twice to perform the necessary action. Any ideas? REDEFINE BUTTON ID 200 OF oDlg ACTION ( EditFl( .F., invoice->file ), _Lbx( oLbx2 ) ) REDEFINE BUTTON ID 201 OF oDlg ACTION _StmPrt( oLbx, nFlParty, invoice->( recno() ) ) REDEFINE BUTTON ID 202 OF oDlg ACTION (lQuit := .T., oDlg:End())
problem with pushbutton
REDEFINE BUTTON ID 200 OF oDlg ACTION ( EditFl( .F., invoice->file ), _Lbx( oLbx2 ) ) Try this : Ich changed all my buttons to Class < BUTTONBMP > like : ----------------------------------------------------------- REDEFINE BUTTONBMP oBtn1 ID 200 OF oDlg ; ACTION ( EditFl( .F., invoice->file ), _Lbx( oLbx2 ) ) ; BITMAP "yourBitmap" PROMPT "Button Text" TEXTRIGHT oBtn1:cTooltip "This is a Test" + CRLF "for ButtonBmp" ------------------------------------------------------------ ( yourBitmap is a Ressourcen-Bitmap ) No changes of the button in the Ressource. TEXTRIGHT = Bitmap = LEFT, TEXTLEFT = Bitmap = RIGHT It looks great ( a normal Button with Bitmap and Tooltip ) That is all, what you have to do. I hope it helps. Greetings from Germany U. König <!-- s:lol: --><img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing" /><!-- s:lol: -->
problem with pushbutton
Darrell, Are you using FWH or FW++ ?
problem with pushbutton
Antonio, I am using FWH lib dates of 12/2007
problem with pushbutton
Darrell, Could you please provide a small and self contained sample to reproduce the problem ? thanks
problem with pushbutton
Here is the source. DEFINE DIALOG oDlg RESOURCE "FRTLIST" REDEFINE GET aGet[01] VAR cFile ID 101 OF oDlg PICTURE "@!" WHEN .F. REDEFINE GET aGet[02] VAR nFlparty ID 102 OF oDlg PICTURE "9" ; VALID ( lPass := _FlOk( nFlParty, @nShare, @nInvCnt, cGroupon, cFlkey, cMbl, oLbx2 ), aGet[03]:Refresh(), lPass ) REDEFINE GET aGet[03] VAR nShare ID 103 OF oDlg PICTURE "99.99" ; VALID ( lPass := _FlOk2( nShare ), aGet[03]:Refresh(), lPass ) REDEFINE GET aGet[04] VAR cMbl ID 104 OF oDlg PICTURE "@!" WHEN .F. REDEFINE GET aGet[05] VAR cHbl ID 105 OF oDlg PICTURE "@!" WHEN .F. REDEFINE COMBOBOX aGet[06] VAR cFlRem ID 106 ITEMS aFlRem OF oDlg ; VALID ( lPass := _FlOk3( cGroupon, cFlkey, cFlRem ), lPass ) SELECT invoice SET ORDER TO TAG S7 GO TOP SEEK cFlkey SET FILTER TO ( invoice->flkey = cFlkey ) REDEFINE LISTBOX oLbx2 FIELDS invoice->type , ; invoice->flkey , ; invoice->invoice , ; DTOC( invoice->invdate ) , ; TRANSF( invoice->totamt, "9,999,999.99" ) , ; TRANSF( invoice->totcst, "9,999,999.99" ) , ; IF( invoice->flprt, "PRINTED","NOT-PRINTED") , ; invoice->fluser , ; invoice->fldate , ; invoice->fltime ; ID 6000 ; HEADERS "Type", "F/L Key", "CR/DB No.", "Ref Date", "Revenue", "Outlay", "Status", "F/L User", "Date", "Time" ; FIELDSIZES 75 , 125 , 125 , 85 , 100 , 100 , 100 , 100 , 85 , 85 ; SELECT invoice->flkey FOR cFlkey ; ON DBLCLICK ( EditFl( .F., invoice->file ), _Lbx( oLbx2 ) ) ; ON CHANGE ( nShare := invoice->flper, aGet[03]:Refresh() ) ; OF oDlg REDEFINE BUTTON ID 200 OF oDlg ACTION ( EditFl( .F., invoice->file ), _Lbx( oLbx2 ) ) REDEFINE BUTTON ID 201 OF oDlg ACTION _StmPrt( oLbx, nFlParty, invoice->( recno() ) ) REDEFINE BUTTON ID 202 OF oDlg ACTION (lQuit := .T., oDlg:End()) ACTIVATE DIALOG oDlg CENTERED
problem with pushbutton
Darrell, REDEFINE BUTTON ID 200 OF oDlg ACTION ( EditFl( .F., invoice->file ), _Lbx( oLbx2 ) ) REDEFINE BUTTON ID 201 OF oDlg ACTION _StmPrt( oLbx, nFlParty, invoice->( recno() ) ) REDEFINE BUTTON ID 202 OF oDlg ACTION (lQuit := .T., oDlg:End()) Can you post the EditFl() and _StmPrt() functions? Does the ID 202 (quit) button also require two clicks? Regards, James
problem with pushbutton
Hi James, Yes, all buttons require two clicks. I placed Msginfo() at the beginning of each function and to make sure I had to click it twice. I do not think it is a problem with editfl() or _stmprt(). Thank you,
problem with pushbutton
If you comment out all the REDEFINEs except the buttons, do they still require two clicks? James
problem with pushbutton
James, Thank you for your advice. I found the problem, it was a problem the valid function. I have corrected and it is working now. Thank you for opening up my eyes
problem with pushbutton
Darrell, Great news. I commonly resort to the 50% method. I take out half the code, then check again. If it is stll there then I have eliminated half the code. Then I eliminate half of the remaining half, etc., until I isolate the problem. This is much faster the eliminating one line at a time. Regards, James
problem with pushbutton
James, Thanks again. By the way, is there a function available to find out what user or computer has locked a specific record?
problem with pushbutton
Darrell, >By the way, is there a function available to find out what user or computer has locked a specific record? Not to my knowledge. There is a discussion about this here: <!-- m --><a class="postlink" href="http://fivetechsoft.com/forums/viewtopic.php?t=8407&highlight=locked">http://fivetechsoft.com/forums/viewtopi ... ght=locked</a><!-- m --> Consider using optimistic locking (edit, lock, save, unlock). This takes only a split second so it is unlikely that a locked record is going to be a problem. If you are using pessimistic locking (lock, edit, save, unlock) then records can end up being locked for very long periods--even days when someone leaves work with a locked record. There is another method that was used back in the DOS era (maybe still is). You add a field to each database for the username. When the record is locked the username is inserted into this field. That way you can read the username when the record is locked. James James
problem with read from xml file
problem with read NUMER from xml file, I get empty NUMER <NUMER> <![CDATA[FA/1/12/2016/EXP]]> </NUMER> which means <![CDATA[
problem with read from xml file
How are you reading it ? Please show the code
problem with read from xml file
sc:=rtrim(init_mem)+'IMPORT' cFileName := cGetFile( "XML File (*.Xml)|*.Xml|","Wybierz zbiór XML",sc) If !file(cFileName) break Endif mTekst:="" @ 100,20 SAY oTEKST var mTekst OF oDlg PIXEL SIZE 150,12 dd:=day(date()) mm:=month(date()) rr:=year(date()) // hFile := FOpen( cFileName ) oXmlDoc := TXmlDocument():new() // HBXML_TYPE_CDATA HBXML_STYLE_NOESCAPE oXmlDoc:read( Memoread( cFileName ) ) // oXmlDoc:read( hFile )
problem with read from xml file
in FWH version 16.06 was ok
problem with read from xml file
Please build a sample showing the problem that can be compiled and run here. EMG
problem with read from xml file
I send samples via mail
problem with read from xml file
Sorry, Thunderbird freezes when I try to open your message. I had to delete it. EMG
problem with read from xml file
I send You compressed
problem with read from xml file
Sorry, I need a [b:223o9frf]reduced[/b:223o9frf] sample. You have to take the time to reduce it at the smallest size yet showing the problem. And please reduce the file xml accordingly. EMG
problem with read from xml file
my sample t1.prg //#include 'fivewin.ch' #include 'hbxml.ch' #define CRLF chr(13)+chr(10) REQUEST DBFCDX //------------------------------------------------------c---------------------// function XML2RK() local oDlg local lSave := .f. local oFont local dd,mm,rr LOCAL oXmlDoc,oXmlNode, oXmlRecScan, oXmlFieldScan setpos(25,80) cls set_4_:=set(4,'yyyy-mm-dd') begin sequence cFileName := 'demo.xml' If !file(cFileName) break Endif cString:=Memoread( cFileName ) // cString:=strtran(cString,'<![CDATA[','') // cString:=strtran(cString,']]>','') oXmlDoc := TXmlDocument():new(,5) // ,HBXML_STYLE_NOESCAPE ) // HBXML_TYPE_CDATA HBXML_STYLE_NOESCAPE if !( oXmlDoc:nError==HBXML_ERROR_NONE ) wait "xml file parsing error " + str(oXmlDoc:nError) break endif oXMlDoc:read( cString ) oXmlNode00 := oXmlDoc:findFirst( "ROOT" ) oXmlRecScan0 := TXmlIteratorScan():new( oXmlNode00 ) oXmlNode0 := oXmlRecScan0:find( "REJESTRY_SPRZEDAZY_VAT" ) DO WHILE oXmlNode0 <> NIL // oXmlFieldScan0 := TXmlIteratorScan():new( oXmlNode0 ) oXmlRecScan := TXmlIteratorScan():new( oXmlNode0 ) oXmlNode := oXmlRecScan:find( "REJESTR_SPRZEDAZY_VAT" ) DO WHILE oXmlNode <> NIL tNUMER:='' tDATA:='' tNETTO:='' oXmlFieldScan := TXmlIteratorScan():new( oXmlNode ) oXmlNode := oXmlFieldScan:find( "DATA" ) if oXmlNode#NIL if oXmlNode:cData#NIL tData:=oXmlNode:cData endif endif oXmlNode := oXmlFieldScan:find( "NUMER" ) if oXmlNode#NIL if oXmlNode:cData#NIL tNUMER:=oXmlNode:cData endif endif oXmlNode := oXmlFieldScan:find( "NETTO" ) if oXmlNode#NIL if oXmlNode:cData#NIL tNETTO:=oXmlNode:cData endif endif alert('Data:'+tDATA+' '+'Numer:'+tNUMER+' '+'Netto:'+tNETTO) oXmlNode := oXmlRecScan:next("REJESTR_SPRZEDAZY_VAT") ENDDO oXmlNode0 := oXmlRecScan0:next("REJESTRY_SPRZEDAZY_VAT") ENDDO end sequence dbcloseall() set(4,set_4_) return //------------------------------------------------------------------------------------// demo.xml ------------------------------------------------------------- <?xml version="1.0" encoding="UTF-8"?> <ROOT xmlns="http://www.comarch.pl/cdn/optima/offline"> <REJESTRY_SPRZEDAZY_VAT> <WERSJA>2.00</WERSJA> <BAZA_ZRD_ID>SPRZE</BAZA_ZRD_ID> <BAZA_DOC_ID>KSIEG</BAZA_DOC_ID> <REJESTR_SPRZEDAZY_VAT> <DATA> <![CDATA[2016-12-01]]> </DATA> <NUMER> <![CDATA[FA/1/12/2016/EXP]]> </NUMER> <NETTO>1400</NETTO> </REJESTR_SPRZEDAZY_VAT> </REJESTRY_SPRZEDAZY_VAT> </ROOT> t1.exe.xbp ------------------------------------------------------------- CINI = C_OUTPUTFOLDER = DEFFILE = INCLUDEFOLDERS = LAUTORUN = LDEBUG = .F. LGUI = .F. LIBFOLDERS = LMT = .F. LNOAUTOFWH = .F. LPRG_CLASSICDEBUG = .F. LPRG_DEBUG = .F. LUSEDLL = .F. MAPFILE = MYC_FLAGS = MYDEFINES = MYLINK_FLAGS = MYPRG_FLAGS = MYRC_FLAGS = MYSLY_FLAGS = OUTPUTFOLDER = PRG_OUTPUTFOLDER = RC_OUTPUTFOLDER = RUNARGUMENTS = SLY_OUTPUTFOLDER = STARTIN = TARGETFOLDER = [t1.prg] MYC_FLAGS = MYDEFINES = MYPRG_FLAGS =
problem with read from xml file
Using [code=fw:19dks2a0]<div class="fw" id="{CB}" style="font-family: monospace;">oXmlNode:<span style="color: #000000;">oChild</span>:<span style="color: #000000;">ToString</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span></div>[/code:19dks2a0] at least you can read the string [code=fw:19dks2a0]<div class="fw" id="{CB}" style="font-family: monospace;"><!<span style="color: #000000;">&#91;</span>CDATA<span style="color: #000000;">&#91;</span><span style="color: #000000;">2016</span><span style="color: #000000;">-12</span><span style="color: #000000;">-01</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#93;</span>></div>[/code:19dks2a0] EMG
problem with read from xml file
if so I do tNUMER:=oXmlNode:oChild:ToString() //oXmlNode:cData because I still getting empty tNumber
problem with read from xml file
Works fine here. EMG
problem with read from xml file
You have to replace this [code=fw:o5gpnw7l]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">if</span> oXmlNode:<span style="color: #000000;">cData</span>#NIL</div>[/code:o5gpnw7l] with this [code=fw:o5gpnw7l]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">if</span> !Empty<span style="color: #000000;">&#40;</span> oXmlNode:<span style="color: #000000;">oChild</span>:<span style="color: #000000;">ToString</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span></div>[/code:o5gpnw7l] and extract the useful data from [code=fw:o5gpnw7l]<div class="fw" id="{CB}" style="font-family: monospace;">oXmlNode:<span style="color: #000000;">oChild</span>:<span style="color: #000000;">ToString</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span></div>[/code:o5gpnw7l] EMG
problem with read from xml file
[quote="kajot":3jbf7wxd]if so I do tNUMER:=oXmlNode:oChild:ToString() //oXmlNode:cData because I still getting empty tNumber[/quote:3jbf7wxd] Are your variable names correct? [b:3jbf7wxd]tNUMER[/b:3jbf7wxd] or [b:3jbf7wxd]tNumber[/b:3jbf7wxd]
problem with read from xml file
Thanks but I getting tNUMER as <>~`<![CDATA[FA/1/12/2016/EXP]]>
problem with read from xml file
Yes, and now you can extract the data from the string. At least you have an option. EMG
problem with read from xml file
in version XHB.COM 16.06 was well i getting tNumer=FA/1/12/2016/EXP
problem with report
The problem with reports for. When printing multiple pages every second, third page is blank. Does anyone encountered a similar problem. Thank you.
problem with report
Davor, Could you please provide an example to reproduce it here ? many thanks,
problem with report
Antonio, this is a small example. I noticed that the problem occurs when I turn in report function cellView (). Thank you for your help. // Testing FiveWin built-in report engine and print preview #include "FiveWin.ch" #include "Report.ch" static oWnd, lPreview := .F. [img:2tcu4q93]http&#58;//i&#46;imgur&#46;com/Rp0IsQF&#46;png[/img:2tcu4q93] function Main() local oBar, oCursorHand DEFINE WINDOW oWnd ; TITLE "Testing FiveWin Report-Engine and Print-Preview" ; MENU BuildMenu() DEFINE BUTTONBAR oBar _3D SIZE 26, 27 OF oWnd DEFINE BUTTON OF oBar FLAT TOOLTIP "Generate report" ; ACTION DoReport() RESOURCE "Report" DEFINE BUTTON OF oBar FLAT GROUP TOOLTIP "Exit" ; ACTION oWnd:End() RESOURCE "Exit" DEFINE CURSOR oCursorHand HAND AEval( oBar:aControls, { | o | o:oCursor := oCursorHand } ) DEFINE MESSAGE BAR OF oWnd TITLE FWCOPYRIGHT ; NOINSET DATE CLOCK KEYBOARD ACTIVATE WINDOW oWnd ; VALID ! lPreview .and. MsgYesNo( "Want to exit ?" ) return nil function BuildMenu() local oMenu MENU oMenu MENUITEM "&Generate Report" ACTION DoReport() ; MESSAGE "Open customers database and generate a report" MENUITEM "&Exit" ACTION oWnd:End() ; MESSAGE "Terminate the application and exit" ENDMENU return oMenu function DoReport() local oRpt lPreview = .T. USE Customer REPORT oRpt; TITLE "Print" ; HEADER "Report" ; FOOTER "Page: "+str(oRpt:nPage,3) RIGHT; PREVIEW COLUMN TITLE "First" DATA Customer->First COLUMN TITLE "Last" DATA Customer->Last COLUMN TITLE "State" DATA Customer->State END REPORT oRpt:CellView() ACTIVATE REPORT oRpt USE lPreview = .F. return nil
problem with report
[code=fw:31yga3x1]<div class="fw" id="{CB}" style="font-family: monospace;"><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;">"Report.Ch"</span><br /><br /><span style="color: #00C800;">STATIC</span> oWnd, lPreview := .F.<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> oBar, oCursorHand<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">CURSOR</span> oCursorHand HAND<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">WINDOW</span> oWnd ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Testing FiveWin Report-Engine and Print-Preview"</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">MENU</span> BuildMenu<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTONBAR</span> oBar _3D <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">26</span>, <span style="color: #000000;">27</span> <span style="color: #0000ff;">OF</span> oWnd<br /><br />&nbsp; &nbsp;AEval<span style="color: #000000;">&#40;</span> oBar:<span style="color: #000000;">aControls</span>, <span style="color: #000000;">&#123;</span> | o | o:<span style="color: #000000;">oCursor</span> := oCursorHand <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">OF</span> oBar FLAT TOOLTIP <span style="color: #ff0000;">"Generate report"</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ACTION</span> DoReport<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Report"</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">OF</span> oBar FLAT GROUP TOOLTIP <span style="color: #ff0000;">"Exit"</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ACTION</span> oWnd:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"Exit"</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">MESSAGE</span> BAR <span style="color: #0000ff;">OF</span> oWnd <span style="color: #0000ff;">TITLE</span> FWCOPYRIGHT ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; NOINSET DATE CLOCK KEYBOARD<br /><br />&nbsp; &nbsp;WndCenter<span style="color: #000000;">&#40;</span> oWnd:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">WINDOW</span> oWnd ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">VALID</span> ! lPreview .and. MsgYesNo<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"Want to exit ?"</span> <span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">function</span> BuildMenu<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> oMenu<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">MENU</span> oMenu<br />&nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">MENUITEM</span> <span style="color: #ff0000;">"&Generate Report"</span> <span style="color: #0000ff;">ACTION</span> DoReport<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> ;<br />&nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Open customers database and generate a report"</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">MENUITEM</span> <span style="color: #ff0000;">"&Exit"</span> <span style="color: #0000ff;">ACTION</span> oWnd:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> ;<br />&nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">MESSAGE</span> <span style="color: #ff0000;">"Terminate the application and exit"</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">ENDMENU</span><br /><br /><span style="color: #00C800;">return</span> oMenu<br /><br /><span style="color: #00C800;">function</span> DoReport<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oPen1, oPen2, oFont1, oFont2, oFont3, oRpt<br /><br />&nbsp; &nbsp;lPreview = .T. &nbsp;<span style="color: #B900B9;">//??</span><br /><br />&nbsp; &nbsp;USE Customer<br />&nbsp; &nbsp;GO TOP<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> PEN oPen1 WIDTH <span style="color: #000000;">2</span><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> PEN oPen2 WIDTH <span style="color: #000000;">1</span> &nbsp; &nbsp; <br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont1 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Arial"</span> &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-11</span><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont2 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Arial"</span> &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">-11</span><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont3 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"Courier New"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>, &nbsp;<span style="color: #000000;">09</span> BOLD<br /><br />&nbsp; &nbsp;REPORT oRpt <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Print - Report Name"</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ;<br />&nbsp; &nbsp; &nbsp; CAPTION <span style="color: #ff0000;">"Report Text Caption"</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; HEADER <span style="color: #ff0000;">"Preview Header - Name Company"</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; , ;<br />&nbsp; &nbsp; &nbsp; <span style="color: #ff0000;">"Date: "</span> &nbsp; + DTOC<span style="color: #000000;">&#40;</span> DATE<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</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; <span style="color: #ff0000;">"Page: "</span> &nbsp; + STR<span style="color: #000000;">&#40;</span> oRpt:<span style="color: #000000;">nPage</span>, <span style="color: #000000;">3</span> <span style="color: #000000;">&#41;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; FOOTER <span style="color: #ff0000;">"- Report Text Footer - "</span> <span style="color: #0000ff;">CENTER</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;;<br />&nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">FONT</span> oFont1, oFont2, oFont3 &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; PEN oPen1, oPen2 &nbsp; &nbsp; &nbsp; &nbsp; &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; PREVIEW<br /><br />&nbsp; &nbsp; &nbsp; oRpt:<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">lPrvModal</span> := .T.<br />&nbsp; &nbsp; &nbsp; oRpt:<span style="color: #000000;">oDevice</span>:<span style="color: #000000;">SetPage</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">9</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp; &nbsp; COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"First"</span> <span style="color: #00C800;">DATA</span> Customer->First<br /><br />&nbsp; &nbsp; &nbsp; COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Last"</span> &nbsp;<span style="color: #00C800;">DATA</span> Customer->Last<br /><br />&nbsp; &nbsp; &nbsp; COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"State"</span> <span style="color: #00C800;">DATA</span> Customer->State<br /><br />&nbsp; &nbsp;END REPORT<br /><br />&nbsp; &nbsp;<span style="color: #00C800;">IF</span> !oRpt:<span style="color: #000000;">lCreated</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span> <br />&nbsp; &nbsp;<span style="color: #00C800;">ENDIF</span><br /><br />&nbsp; &nbsp;oRpt:<span style="color: #000000;">CellView</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">ACTIVATE</span> REPORT oRpt <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">INIT</span> oRpt:<span style="color: #000000;">oTitle</span>:<span style="color: #000000;">aFont</span><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span> := <span style="color: #000000;">&#123;</span> || <span style="color: #000000;">3</span> <span style="color: #000000;">&#125;</span><br /><br />&nbsp; &nbsp;oPen1:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> &nbsp;<br />&nbsp; &nbsp;oPen2:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> &nbsp;<br />&nbsp; &nbsp;oFont1:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <br />&nbsp; &nbsp;oFont2:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <br />&nbsp; &nbsp;oFont3:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;USE<br /><br />&nbsp; &nbsp;lPreview = .F.<br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #B900B9;">// END</span><br />&nbsp;</div>[/code:31yga3x1] Regards, 
problem with report
Congratulations. I was happy now. Regards,
problem with report
Mr. Karinha thanks for your help, now everything works ok. Regards Davor.
problem with report to excel
Patrick, Can you put your source here? Thanks.
problem with report to excel
[code=fw:ffy7stmq]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">FUNCTION</span> nbalcli<span style="color: #000000;">&#40;</span>gl,complet<span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">local</span> ofont1,ofont2<br /><br /><span style="color: #00C800;">default</span> complet <span style="color: #0000ff;">to</span> .f.<br /><span style="color: #00C800;">default</span> gl <span style="color: #0000ff;">to</span> .f.<br /><br /><span style="color: #00C800;">if</span> faire<br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont1 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"andale mono"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>,<span style="color: #000000;">-9</span><br /><span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont2 <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"andale mono"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>,<span style="color: #000000;">-9</span> BOLD<br /><br />mess := <span style="color: #00C800;">if</span><span style="color: #000000;">&#40;</span>gl,<span style="color: #ff0000;">"LE GRAND LIVRE"</span>,<span style="color: #ff0000;">"LA BALANCE"</span><span style="color: #000000;">&#41;</span><br /><br />opar := oserver:<span style="color: #000000;">query</span><span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"select * from param"</span><span style="color: #000000;">&#41;</span><br />moisref := str<span style="color: #000000;">&#40;</span>pannee,<span style="color: #000000;">4</span><span style="color: #000000;">&#41;</span>+<span style="color: #ff0000;">"-"</span>+strzero<span style="color: #000000;">&#40;</span>pmois,<span style="color: #000000;">2</span><span style="color: #000000;">&#41;</span><br />arrete := ctod<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"01/"</span>+strzero<span style="color: #000000;">&#40;</span>pmois,<span style="color: #000000;">2</span><span style="color: #000000;">&#41;</span>+<span style="color: #ff0000;">"/"</span>+str<span style="color: #000000;">&#40;</span>pannee,<span style="color: #000000;">4</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">if</span> complet<br />&nbsp;laq := <span style="color: #ff0000;">"select facture.*,clients.nom as nnom from facture inner join clients on clients.tiers = facture.tiers where facture.tiers between "</span>+c2s<span style="color: #000000;">&#40;</span>cli1<span style="color: #000000;">&#41;</span>+<span style="color: #ff0000;">" and "</span>+c2s<span style="color: #000000;">&#40;</span>cli2<span style="color: #000000;">&#41;</span>+;<br />&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #ff0000;">" and facture.interne = "</span>+c2s<span style="color: #000000;">&#40;</span>.F.<span style="color: #000000;">&#41;</span>+ <span style="color: #ff0000;">" and left(datef,7) <= "</span>+c2s<span style="color: #000000;">&#40;</span>moisref<span style="color: #000000;">&#41;</span><br />&nbsp;lorder := <span style="color: #ff0000;">" order by facture.tiers,facture.datef"</span><br /><span style="color: #00C800;">else</span><br />&nbsp;laq := <span style="color: #ff0000;">"select facture.*,clients.nom as nnom from facture inner join clients on clients.tiers = facture.tiers "</span><br />&nbsp;laq += <span style="color: #ff0000;">"where facture.interne = "</span>+c2s<span style="color: #000000;">&#40;</span>.F.<span style="color: #000000;">&#41;</span>+ <span style="color: #ff0000;">" and left(datef,7) <= "</span>+c2s<span style="color: #000000;">&#40;</span>moisref<span style="color: #000000;">&#41;</span>+<span style="color: #ff0000;">" and (reglement+acompte) <> montant"</span><br /><br />&nbsp;lorder := <span style="color: #ff0000;">" order by nnom,facture.datef"</span><br /><span style="color: #00C800;">endif</span><br /><br /><span style="color: #B900B9;">//tribal := alert("Balance génerale",{"Générale","Par commerciaux"})</span><br /><span style="color: #B900B9;">//lorder := if( tribal = 2," order by commerciaux,tiers,datef"," order by nom,tiers,datef")</span><br /><br />bal := oserver:<span style="color: #000000;">query</span><span style="color: #000000;">&#40;</span>laq+lorder<span style="color: #000000;">&#41;</span><br />memowrit<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"laq.sql"</span>,bal:<span style="color: #000000;">cquery</span><span style="color: #000000;">&#41;</span><br /><br />lbtiers:= bal:<span style="color: #000000;">tiers</span><br /><br />REPORT oReport <span style="color: #0000ff;">TITLE</span> &nbsp;opar:<span style="color: #000000;">societe</span>,mess+<span style="color: #ff0000;">" CLIENTS"</span>,<span style="color: #ff0000;">"Au "</span>+<span style="color: #0000ff;">right</span><span style="color: #000000;">&#40;</span>dtoc<span style="color: #000000;">&#40;</span>arrete<span style="color: #000000;">&#41;</span>,<span style="color: #000000;">7</span><span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">LEFT</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;FOOTER <span style="color: #000000;">&#40;</span><span style="color: #ff0000;">"Page: "</span><span style="color: #000000;">&#41;</span>+ltrim<span style="color: #000000;">&#40;</span>str<span style="color: #000000;">&#40;</span>oReport:<span style="color: #000000;">nPage</span>,<span style="color: #000000;">3</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">FONT</span> oFont1, oFont2 &nbsp;PREVIEW<br /><span style="color: #00C800;">if</span> gl<br />COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Renseignement"</span> <span style="color: #00C800;">DATA</span> dtoc<span style="color: #000000;">&#40;</span>bal:<span style="color: #000000;">datef</span><span style="color: #000000;">&#41;</span>+<span style="color: #ff0000;">" -- "</span>+bal:<span style="color: #000000;">factno</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">50</span> <span style="color: #0000ff;">FONT</span> <span style="color: #000000;">1</span> GRID<br />COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Debit"</span> &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00C800;">DATA</span> bal:<span style="color: #000000;">montant</span> <span style="color: #0000ff;">FONT</span> <span style="color: #000000;">2</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@Z 999 999 999"</span> &nbsp; TOTAL <span style="color: #0000ff;">RIGHT</span> GRID<br />COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Crédit"</span> &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00C800;">DATA</span> bal:<span style="color: #000000;">reglement</span>+bal:<span style="color: #000000;">acompte</span> &nbsp; <span style="color: #0000ff;">FONT</span> <span style="color: #000000;">2</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@Z 999 999 999"</span> &nbsp;TOTAL <span style="color: #0000ff;">RIGHT</span> GRID<br />COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Solde"</span> &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00C800;">DATA</span> bal:<span style="color: #000000;">montant</span>-<span style="color: #000000;">&#40;</span>bal:<span style="color: #000000;">reglement</span>+bal:<span style="color: #000000;">acompte</span><span style="color: #000000;">&#41;</span> &nbsp; <span style="color: #0000ff;">FONT</span> <span style="color: #000000;">2</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@Z 999 999 999"</span> &nbsp; TOTAL <span style="color: #0000ff;">RIGHT</span> GRID<br /><span style="color: #00C800;">else</span><br />COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Libellé"</span> &nbsp; <span style="color: #00C800;">DATA</span> pad<span style="color: #000000;">&#40;</span><span style="color: #ff0000;">" "</span>,<span style="color: #000000;">45</span><span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">45</span> <span style="color: #0000ff;">FONT</span> <span style="color: #000000;">1</span> GRID<br />COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Debit"</span> &nbsp; &nbsp; <span style="color: #00C800;">DATA</span> bal:<span style="color: #000000;">montant</span> <span style="color: #0000ff;">FONT</span> <span style="color: #000000;">2</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@Z 999 999 999"</span> &nbsp; TOTAL <span style="color: #0000ff;">RIGHT</span> GRID<br />COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Crédit"</span> &nbsp; &nbsp;<span style="color: #00C800;">DATA</span> bal:<span style="color: #000000;">reglement</span>+bal:<span style="color: #000000;">acompte</span> &nbsp; <span style="color: #0000ff;">FONT</span> <span style="color: #000000;">2</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@Z 999 999 999"</span> &nbsp;TOTAL <span style="color: #0000ff;">RIGHT</span> GRID<br />COLUMN <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Solde"</span> &nbsp; &nbsp; <span style="color: #00C800;">DATA</span> bal:<span style="color: #000000;">montant</span>-<span style="color: #000000;">&#40;</span>bal:<span style="color: #000000;">reglement</span>+bal:<span style="color: #000000;">acompte</span><span style="color: #000000;">&#41;</span> &nbsp; <span style="color: #0000ff;">FONT</span> <span style="color: #000000;">2</span> <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@Z 999 999 999"</span> &nbsp; TOTAL <span style="color: #0000ff;">RIGHT</span> GRID<br /><span style="color: #00C800;">endif</span><br /><br />GROUP <span style="color: #0000ff;">ON</span> bal:<span style="color: #000000;">nnom</span> &nbsp;FOOTER padl<span style="color: #000000;">&#40;</span>lbtiers,<span style="color: #000000;">6</span>,<span style="color: #ff0000;">'0'</span><span style="color: #000000;">&#41;</span>+<span style="color: #ff0000;">" "</span>+oreport:<span style="color: #000000;">agroups</span><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span>:<span style="color: #000000;">cvalue</span> &nbsp;<span style="color: #0000ff;">FONT</span> <span style="color: #000000;">2</span><br />END REPORT<br /><br />oReport:<span style="color: #000000;">oTitle</span>:<span style="color: #000000;">aFont</span><span style="color: #000000;">&#91;</span><span style="color: #000000;">1</span><span style="color: #000000;">&#93;</span> := <span style="color: #000000;">&#123;</span>|| <span style="color: #000000;">2</span> <span style="color: #000000;">&#125;</span><br />setrsql<span style="color: #000000;">&#40;</span>bal,oreport<span style="color: #000000;">&#41;</span><br />oreport:<span style="color: #000000;">lsummary</span> := <span style="color: #00C800;">if</span><span style="color: #000000;">&#40;</span>gl,.f.,.t.<span style="color: #000000;">&#41;</span><br />oreport:<span style="color: #000000;">ljoin</span> := .t.<br />oreport:<span style="color: #000000;">lboxontotal</span> := .t.<br />oreport:<span style="color: #000000;">odevice</span>:<span style="color: #000000;">lPrvModal</span> := .t.<br />oreport:<span style="color: #000000;">odevice</span>:<span style="color: #000000;">cdir</span> := chepers<br /><br /><span style="color: #0000ff;">ACTIVATE</span> REPORT oReport <span style="color: #0000ff;">ON</span> STARTGROUP &nbsp;<span style="color: #000000;">&#40;</span>lbtiers:= bal:<span style="color: #000000;">tiers</span><span style="color: #000000;">&#41;</span><br />oFont1:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />oFont2:<span style="color: #000000;">End</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br /><span style="color: #00C800;">endif</span><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">function</span> setrsql<span style="color: #000000;">&#40;</span>osql,oreport<span style="color: #000000;">&#41;</span><br />oreport:<span style="color: #000000;">bSkip</span> &nbsp;:= <span style="color: #000000;">&#123;</span>|n| osql:<span style="color: #000000;">skip</span><span style="color: #000000;">&#40;</span>n<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#125;</span><br />oreport:<span style="color: #000000;">bwhile</span> := <span style="color: #000000;">&#123;</span>|| ! osql:<span style="color: #000000;">Eof</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span> &nbsp;<br />oreport:<span style="color: #000000;">bInit</span> &nbsp;:= <span style="color: #000000;">&#123;</span>|| osql:<span style="color: #000000;">GOTOP</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br />&nbsp;</div>[/code:ffy7stmq]
problem with report to excel
Each time I try to export report to excel I have this error; Time from start: 0 hours 0 mins 27 secs Error occurred at: 13/10/2013, 17:50:08 Error description: (DOS Error -2147352567) WINOLE/1006 (0x800A03EC): _FORMULA Args: [ 1] = C =SUBTOTAL(9,B7:B25) Stack Calls =========== Called from: => TOLEAUTO:_FORMULA( 0 ) Called from: .\source\classes\REPORT.PRG => TREPORT:TOEXCEL( 2167 ) Called from: .\source\classes\RPREVIEW.PRG => (b)TPREVIEW( 81 ) Called from: .\source\classes\RPREVIEW.PRG => TPREVIEW:EXPORTTOMSEXCEL( 0 ) Called from: .\source\classes\RPREVIEW.PRG => (b)TPREVIEW_BUILDBUTTONBAR( 362 ) Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:CLICK( 471 ) Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:LBUTTONUP( 662 ) Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1723 ) Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 1465 ) Called from: .\source\classes\WINDOW.PRG => _FWH( 3234 ) Called from: => SYSREFRESH( 0 ) Called from: .\source\function\MSGRUN.PRG => STOPUNTIL( 60 ) Called from: .\source\classes\RPREVIEW.PRG => TPREVIEW:ACTIVATE( 143 ) Called from: .\source\classes\RPREVIEW.PRG => RPREVIEW( 1767 ) Called from: .\source\classes\REPORT.PRG => (b)TREPORT_NEW( 170 ) Called from: .\source\classes\REPORT.PRG => TREPORT:ACTIVATE( 850 ) Called from: Exobal.prg => NBALCLI( 1453 ) Called from: EXO.PRG => (b)BUILDMENU( 509 ) Called from: .\source\classes\MENU.PRG => TMENU:COMMAND( 463 ) Called from: .\source\classes\WINDOW.PRG => TWINDOW:COMMAND( 1050 ) Called from: .\source\classes\MDIFRAME.PRG => TMDIFRAME:COMMAND( 255 ) Called from: => TMDIFRAME:HANDLEEVENT( 0 ) Called from: .\source\classes\WINDOW.PRG => _FWH( 3234 ) Called from: => WINRUN( 0 ) Called from: .\source\classes\WINDOW.PRG => TMDIFRAME:ACTIVATE( 1003 ) Called from: EXO.PRG => MAIN( 80 ) Harbour 3.2.0dev (r1307180024) Fivewin 13.08 Microsoft Visual Studio 2010 Version 10.0.30319.1 RTMRel Version installée : VC Express
problem with report to excel
Which language is your Excel is installed for?
problem with report to excel
Excel is installed in French Thanks
problem with report to excel
Will you please make this correction in report.prg? Please locate the string '=SUBTOTAL(9,' and substitute it with '=SOUS.TOTAL(9;' We would be glad if you can let us know if this modification works for French installation of Excel.
problem with report to excel
Thank you for your answer. with this change [quote:onpmn9k2]Please locate the string '=SUBTOTAL(9,' and substitute it with '=SOUS.TOTAL(9;' [/quote:onpmn9k2] no error, but when the report is summarize oreport:lsummary := .T. //if(gl,.f.,.t.) Excel sheet does not reflect the fivewin report. it contains details I prepare samples to show this behavior thank you again Patrick
problem with report to excel
At present, method toExcel() does not support summary reports. Only full reports. Please let us know if the group and report totals are exported to excel correctly without errors with this change ( for full reports ).
problem with report to excel
With this change ( for full reports ), the group and report totals are exported to excel correctly without errors Do you think that this Method toExcel() will support summary reports ?
problem with report to excel
We shall provide that in future releases.
problem with report to excel
[quote="nageswaragunupudi":14ulcf2f]Will you please make this correction in report.prg? Please locate the string '=SUBTOTAL(9,' and substitute it with '=SOUS.TOTAL(9;' We would be glad if you can let us know if this modification works for French installation of Excel.[/quote:14ulcf2f] I changed the file report.prg '=SUBTOTAAL(9;' but stil have the same error.
problem with report to excel
SUBTOTAAL or SUBTOTAL ? What is Excel installation language?
problem with report to excel
Hello Mr. Rao, Excel is installed in Dutch. So '=SUBTOTAL(9,' was changed into 'SUBTOTAAL(9;' Kind regards, Bart
problem with report to excel
[quote:157bhitw]Excel is installed in Dutch. So '=SUBTOTAL(9,' was changed into 'SUBTOTAAL(9;' [/quote:157bhitw] I see. So will you be kind enough to let us know what is working correctly with Dutch installation of Excel? Also please try oBrw:ToExcel() from XBrowse, Both have the same language issues for SUBTOTAL. Please help us to support Dutch installation by advising us the correct keyword and usage. Thanks in advance.
problem with report to excel
Hello Mr. Rao, The Excel formula in Dutch is "=SUBTOTAAL(9;" However when changing the report.prg file with the correct formula this has no effect. Application =========== Path and name: C:\Users\bartv\OneDrive\BKH\fwbkhmain.exe (64 bits) Size: 4,384,768 bytes Compiler version: Harbour 3.2.0dev (r1412151448) FiveWin Version: FWH 15.01 Windows version: 6.2, Build 9200 Time from start: 0 hours 0 mins 31 secs Error occurred at: 04/09/2023, 13:24:57 Error description: (DOS Error -2147352567) WINOLE/1006 (0x800A03EC): _FORMULA Args: [ 1] = C =SUBTOTAL(9,D4:D12) Stack Calls =========== Called from: => TOLEAUTO:_FORMULA( 0 ) Called from: .\source\classes\REPORT.PRG => TREPORT:TOEXCEL( 0 ) Called from: .\source\classes\RPREVIEW.PRG => (b)TPREVIEW( 0 ) Called from: .\source\classes\RPREVIEW.PRG => TPREVIEW:EXPORTTOMSEXCEL( 0 ) Called from: .\source\classes\RPREVIEW.PRG => (b)TPREVIEW_BUILDBUTTONBAR( 0 ) Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:CLICK( 0 ) Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:LBUTTONUP( 0 ) Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 0 ) Called from: .\source\classes\BTNBMP.PRG => TBTNBMP:HANDLEEVENT( 0 ) Called from: .\source\classes\WINDOW.PRG => _FWH( 0 ) Called from: => SYSREFRESH( 0 ) Called from: .\source\function\MSGRUN.PRG => STOPUNTIL( 0 ) Called from: .\source\classes\RPREVIEW.PRG => TPREVIEW:ACTIVATE( 0 ) Called from: .\source\classes\RPREVIEW.PRG => RPREVIEW( 0 ) Called from: .\source\classes\REPORT.PRG => (b)TREPORT_NEW( 0 ) Called from: .\source\classes\REPORT.PRG => TREPORT:ACTIVATE( 0 ) Called from: fwbkhreport.prg => PRINT_VERKOOPDAGBOEK( 245 ) Thanks in advance for your help. Best regards Bart
problem with report to excel
As of now we are supporting Excel language translations for only 1 English, 2 Spanish, 3 French, 4 Portuguese, 5 German, 6 Italian 'en', 'es', 'fr', 'pt', 'de', 'it' With your help and support, we will try to provide support for Dutch also. Please help me with this information: 1) Like 'de' for German, 'es' for Spanish, what is it for Dutch? 2) Please provide translations for: SUBTOTAL( -> SUBTOTAAL( SUM( --> ??? TRUE --> ??? FALSE --> ??? Please run the small test and let us know the results: [code=fw:zw29ruax]<div class="fw" id="{CB}" style="font-family: monospace;"><br />oExcel &nbsp; &nbsp; &nbsp; &nbsp; := ExcelObj<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />? nExcelLangID &nbsp; := oExcel:<span style="color: #000000;">LanguageSettings</span>:<span style="color: #000000;">LanguageID</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span><br />? cDecimalSeparator &nbsp; &nbsp;:= oExcel:<span style="color: #000000;">International</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span><br />? cThousandsSeparator &nbsp;:= oExcel:<span style="color: #000000;">International</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span><br />? cListSeparator &nbsp; &nbsp; &nbsp; := oExcel:<span style="color: #000000;">International</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">5</span> <span style="color: #000000;">&#93;</span><br />&nbsp;</div>[/code:zw29ruax] If you don't mind me asking, are you from Netherlands?
problem with report to excel
Please try if this change is working for you [code=fw:2qpootbq]<div class="fw" id="{CB}" style="font-family: monospace;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cFormula:= <span style="color: #ff0000;">"SUBTOTAAL("</span> + ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; LTrim<span style="color: #000000;">&#40;</span> Str<span style="color: #000000;">&#40;</span> FW_DeCode<span style="color: #000000;">&#40;</span> IfNil<span style="color: #000000;">&#40;</span> oCol:<span style="color: #000000;">nFooterType</span>, <span style="color: #000000;">0</span> <span style="color: #000000;">&#41;</span>, AGGR_SUM, <span style="color: #000000;">9</span>, AGGR_MAX, <span style="color: #000000;">4</span>, AGGR_MIN, <span style="color: #000000;">5</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; AGGR_COUNT, <span style="color: #000000;">3</span>, AGGR_AVG, <span style="color: #000000;">1</span>, AGGR_STDEV, <span style="color: #000000;">7</span>, AGGR_STDEVP, <span style="color: #000000;">8</span>, <span style="color: #000000;">9</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> + ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff0000;">";"</span> + ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; oSheet:<span style="color: #000000;">Range</span><span style="color: #000000;">&#40;</span> oSheet:<span style="color: #000000;">Cells</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">2</span>, nCol <span style="color: #000000;">&#41;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; oSheet:<span style="color: #000000;">Cells</span><span style="color: #000000;">&#40;</span> nRow - <span style="color: #000000;">1</span>, nCol <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Address</span><span style="color: #000000;">&#40;</span> .f., .f. <span style="color: #000000;">&#41;</span> + ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff0000;">")"</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; oSheet:<span style="color: #000000;">Cells</span><span style="color: #000000;">&#40;</span> nRow, nCol <span style="color: #000000;">&#41;</span>:<span style="color: #000000;">Formula</span> := <span style="color: #ff0000;">'='</span> + cFormula<br />&nbsp;</div>[/code:2qpootbq]
problem with report to excel
Hello Mr. Rao, 1) Like 'de' for German, 'es' for Spanish, what is it for Dutch? -> 'nl' is the iso code for Dutch and Flemish. 2) Please provide translations for: SUBTOTAL( -> SUBTOTAAL( SUM( --> ??? - > SOM( TRUE --> ??? -> WAAR FALSE --> ??? -> ONWAAR Language ID = 1043 Decimal separator = , Thousands separator = . List separator = ; I live in Belgium. Best regards Bart
problem with report to excel
Can you please make these changes in fwh\source\function\olefuncs.prg and test with toexcel() methods of Report and XBrowse please? Please replace these three functions [code=fw:30kh7cv8]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">function</span> ExcelLangID<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">function</span> ExcelLang<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">function</span> ExcelTranslate<span style="color: #000000;">&#40;</span> cFunc <span style="color: #000000;">&#41;</span><br /> </div>[/code:30kh7cv8] with these modified functions: [code=fw:30kh7cv8]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">function</span> ExcelLangID<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />   <span style="color: #00C800;">local</span> oExcel<br />   <span style="color: #00C800;">local</span> aID   := <span style="color: #000000;">&#123;</span> ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #000000;">1033</span>, <span style="color: #000000;">2057</span>, <span style="color: #000000;">10249</span>, <span style="color: #000000;">4105</span>, <span style="color: #000000;">9225</span>, <span style="color: #000000;">14345</span>, <span style="color: #000000;">6153</span>, <span style="color: #000000;">8201</span>, <span style="color: #000000;">5129</span>, <span style="color: #000000;">13321</span>, <span style="color: #000000;">7177</span>, <span style="color: #000000;">11273</span>, <span style="color: #000000;">12297</span> <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #000000;">3082</span>,<span style="color: #000000;">1034</span>,<span style="color: #000000;">11274</span>,<span style="color: #000000;">16394</span>,<span style="color: #000000;">13322</span>,<span style="color: #000000;">9226</span>,<span style="color: #000000;">5130</span>,<span style="color: #000000;">7178</span>,<span style="color: #000000;">12298</span>,<span style="color: #000000;">17418</span>,<span style="color: #000000;">4106</span>,<span style="color: #000000;">18442</span>,;<br />                     <span style="color: #000000;">58378</span>,<span style="color: #000000;">2058</span>,<span style="color: #000000;">19466</span>,<span style="color: #000000;">6154</span>,<span style="color: #000000;">15370</span>,<span style="color: #000000;">10250</span>,<span style="color: #000000;">20490</span>,<span style="color: #000000;">21514</span>,<span style="color: #000000;">14346</span>,<span style="color: #000000;">8202</span> <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #000000;">1036</span>,<span style="color: #000000;">2060</span>,<span style="color: #000000;">11276</span>,<span style="color: #000000;">3084</span>,<span style="color: #000000;">9228</span>,<span style="color: #000000;">12300</span>,<span style="color: #000000;">15372</span>,<span style="color: #000000;">5132</span>,<span style="color: #000000;">13324</span>,<span style="color: #000000;">6156</span>,<span style="color: #000000;">14348</span>,<span style="color: #000000;">58380</span>,<span style="color: #000000;">8204</span>,<span style="color: #000000;">10252</span>,<span style="color: #000000;">4108</span>,<span style="color: #000000;">7180</span> <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #000000;">1046</span>, <span style="color: #000000;">2070</span> <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #000000;">1031</span>,<span style="color: #000000;">3079</span>,<span style="color: #000000;">5127</span>,<span style="color: #000000;">4103</span>,<span style="color: #000000;">2055</span> <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #000000;">1040</span>, <span style="color: #000000;">2064</span> <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #000000;">1043</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#125;</span><br /><br />   <span style="color: #B900B9;">// 1 English, 2 Spanish, 3 French, 4 Portuguese, 5 German, 6 Italian, 7 Dutch</span><br /><br />   <span style="color: #00C800;">if</span> nExcelLangID == <span style="color: #00C800;">nil</span><br />      oExcel         := ExcelObj<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />      nExcelLangID   := <span style="color: #00C800;">If</span><span style="color: #000000;">&#40;</span> oExcel == <span style="color: #00C800;">nil</span>, <span style="color: #000000;">0</span>, oExcel:<span style="color: #000000;">LanguageSettings</span>:<span style="color: #000000;">LanguageID</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />      nExcelLangNo   := AScan<span style="color: #000000;">&#40;</span> aID, <span style="color: #000000;">&#123;</span> |a| AScan<span style="color: #000000;">&#40;</span> a, nExcelLangID <span style="color: #000000;">&#41;</span> > <span style="color: #000000;">0</span> <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span><br />      <span style="color: #00C800;">TRY</span><br />         cDecimalSeparator    := oExcel:<span style="color: #000000;">International</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span><br />         cThousandsSeparator  := oExcel:<span style="color: #000000;">International</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">4</span> <span style="color: #000000;">&#93;</span><br />         cListSeparator       := oExcel:<span style="color: #000000;">International</span><span style="color: #000000;">&#91;</span> <span style="color: #000000;">5</span> <span style="color: #000000;">&#93;</span><br />      CATCH<br />      END<br />   <span style="color: #00C800;">endif</span><br /><br /><span style="color: #00C800;">return</span> nExcelLangID<br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><br /><span style="color: #00C800;">function</span> ExcelLang<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />   <span style="color: #00C800;">if</span> nExcelLangNo == <span style="color: #00C800;">nil</span><br />      ExcelLangID<span style="color: #000000;">&#40;</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: #000000;">&#123;</span> <span style="color: #ff0000;">'en'</span>, <span style="color: #ff0000;">'es'</span>, <span style="color: #ff0000;">'fr'</span>, <span style="color: #ff0000;">'pt'</span>, <span style="color: #ff0000;">'de'</span>, <span style="color: #ff0000;">'it'</span>, <span style="color: #ff0000;">'nl'</span> <span style="color: #000000;">&#125;</span><span style="color: #000000;">&#91;</span> <span style="color: #0000ff;">Max</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">1</span>, nExcelLangNo <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#93;</span><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><br /><span style="color: #00C800;">function</span> ExcelTranslate<span style="color: #000000;">&#40;</span> cFunc <span style="color: #000000;">&#41;</span><br /><br />   <span style="color: #00C800;">local</span> cRet, nAt, cName<br /><br />   <span style="color: #B900B9;">// 1 English, 2 Spanish, 3 French, 4 Portuguese, 5 German, 6 Italian, 7 Dutch</span><br />   <span style="color: #00C800;">local</span> aTranslates := <span style="color: #000000;">&#123;</span> ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"TRUE"</span>,      <span style="color: #ff0000;">"VERDADERO"</span>,   <span style="color: #ff0000;">"VRAI"</span>,        <span style="color: #ff0000;">"VERDADEIRO"</span>, <span style="color: #ff0000;">"WAHR"</span>,          <span style="color: #ff0000;">"VERO"</span>,       <span style="color: #ff0000;">"WAAR"</span>   <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"FALSE"</span>,     <span style="color: #ff0000;">"FALSO"</span>,       <span style="color: #ff0000;">"FAUX"</span>,        <span style="color: #ff0000;">"FALSO"</span>,      <span style="color: #ff0000;">"FALSCH"</span>,        <span style="color: #ff0000;">"FALSO"</span>,      <span style="color: #ff0000;">"ONWAAR"</span> <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"SUM("</span>,      <span style="color: #ff0000;">"SUMA("</span>,       <span style="color: #ff0000;">"SOMME("</span>,      <span style="color: #ff0000;">"SOMA("</span>,      <span style="color: #ff0000;">"SUMME("</span>,        <span style="color: #ff0000;">"SOMMA("</span>,     <span style="color: #ff0000;">"SOM("</span>   <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"SUBTOTAL("</span>, <span style="color: #ff0000;">"SUBTOTALES("</span>, <span style="color: #ff0000;">"SOUS.TOTAL("</span>, <span style="color: #ff0000;">"SUBTOTAL("</span>,  <span style="color: #ff0000;">"TEILERGEBNIS("</span>, <span style="color: #ff0000;">"SUBTOTALE("</span>, <span style="color: #ff0000;">"SUBTOTAAL("</span> <span style="color: #000000;">&#125;</span>, ;<br />   <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">','</span>,         <span style="color: #ff0000;">';'</span>,           <span style="color: #ff0000;">';'</span>,           <span style="color: #ff0000;">';'</span>,          <span style="color: #ff0000;">';'</span>,              <span style="color: #ff0000;">';'</span>,         <span style="color: #ff0000;">';'</span> <span style="color: #000000;">&#125;</span> ;<br />   <span style="color: #000000;">&#125;</span><br /><br />   <span style="color: #00C800;">if</span> nExcelLangNo == <span style="color: #00C800;">nil</span><br />      ExcelLangID<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">endif</span><br />   cFunc       := Upper<span style="color: #000000;">&#40;</span> cFunc <span style="color: #000000;">&#41;</span><br />   cRet        := cFunc<br />   <span style="color: #00C800;">if</span> nExcelLangNo > <span style="color: #000000;">1</span> .and. nExcelLangNo <= <span style="color: #000000;">7</span><br />      <span style="color: #B900B9;">// Translation required</span><br />      cName    := cFunc<br />      <span style="color: #00C800;">if</span> <span style="color: #000000;">&#40;</span> nAt := <span style="color: #00C800;">At</span><span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">'('</span>, cFunc <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> > <span style="color: #000000;">0</span><br />         cName    := <span style="color: #0000ff;">Left</span><span style="color: #000000;">&#40;</span> cFunc, nAt <span style="color: #000000;">&#41;</span><br />      <span style="color: #00C800;">endif</span><br />      <span style="color: #00C800;">if</span> <span style="color: #000000;">&#40;</span> nAt := AScan<span style="color: #000000;">&#40;</span> aTranslates, <span style="color: #000000;">&#123;</span> |a| a<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span> == cName <span style="color: #000000;">&#125;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> > <span style="color: #000000;">0</span><br />         cRet     := StrTran<span style="color: #000000;">&#40;</span> cFunc, cName, aTranslates<span style="color: #000000;">&#91;</span> nAt, nExcelLangNo <span style="color: #000000;">&#93;</span> <span style="color: #000000;">&#41;</span><br />      <span style="color: #00C800;">endif</span><br />   elseif nExcelLangNo != <span style="color: #000000;">1</span><br />      <span style="color: #00C800;">if</span> cRet == <span style="color: #ff0000;">"TRUE"</span>;  cRet := <span style="color: #ff0000;">"1=1"</span>; <span style="color: #00C800;">endif</span><br />      <span style="color: #00C800;">if</span> cRet == <span style="color: #ff0000;">"FALSE"</span>; cRet := <span style="color: #ff0000;">"1=0"</span>; <span style="color: #00C800;">endif</span><br />   <span style="color: #00C800;">endif</span><br /><br />   <span style="color: #00C800;">if</span> cListSeparator != <span style="color: #ff0000;">','</span><br />      cRet     := StrTran<span style="color: #000000;">&#40;</span> cRet, <span style="color: #ff0000;">','</span>, cListSeparator <span style="color: #000000;">&#41;</span><br />   <span style="color: #00C800;">endif</span><br /><br /><span style="color: #00C800;">return</span> cRet<br /> </div>[/code:30kh7cv8] Please provide your feedback. Please use the original xbrowse and report programs of FWH without modifications.
problem with romanian characters and LoadValue()
i have some words in romanian (for example: 'înv??at') language stored in a dll, in the file dll the string is visualized with all the special characters. when i load with fivewin (1705 version) LoadValue(nnnn, "CHARACTER") function the special characters are lost. any suggestion? thanks
problem with spinner get
I have this REDEFINE GET ::oRight VAR ::nRight ID 102 OF oDlg ; PICTURE "9.9 cm " UPDATE ; SPINNER ON UP ( 0.1 ) ON DOWN ( 0.1 ) MIN 0 MAX 5 why it not run ? I can press the spinner but it not move the value why ?
problem with spinner get
Silvio, Try this: REDEFINE GET ::oRight VAR ::nRight ID 102 OF oDlg ; PICTURE "9.9 cm " UPDATE ; SPINNER ON UP ::nRight += 0.1 ON DOWN ::nRight -= 0.1 MIN 0 MAX 5
problem with spinner get
Antonio, not run ok I can press only once the it not run this is all dialog [code=fw:hqxh5mt9]<div class="fw" id="{CB}" style="font-family: monospace;"> <br /><br /><span style="color: #00C800;">LOCAL</span> aIndent := ::<span style="color: #000000;">WndChild</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">GetIndent</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> lOk &nbsp; &nbsp; := .F.<br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oDlg<br />&nbsp; &nbsp;<span style="color: #00C800;">Local</span> nTab &nbsp; &nbsp;:= &nbsp;::<span style="color: #000000;">WndChild</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">GetTabStop</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br /><br />&nbsp; &nbsp;::<span style="color: #000000;">nLeft</span> &nbsp;:= nLeft &nbsp;:= aIndent<span style="color: #000000;">&#91;</span> <span style="color: #000000;">1</span> <span style="color: #000000;">&#93;</span><br />&nbsp; &nbsp;::<span style="color: #000000;">nRight</span> := nRight := aIndent<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span><br />&nbsp; &nbsp;::<span style="color: #000000;">nFirst</span> := nFirst := aIndent<span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span><br />&nbsp; &nbsp;::<span style="color: #000000;">nTab</span> &nbsp; := nTab<br /><br />&nbsp; &nbsp;::<span style="color: #000000;">nAlign</span> := nAlign := ::<span style="color: #000000;">WndChild</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #000000;">GetAlign</span><span style="color: #000000;">&#40;</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;">RESOURCE</span> <span style="color: #ff0000;">"Paragraph"</span> <span style="color: #0000ff;">FONT</span> ::<span style="color: #000000;">oFont</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">GET</span> ::<span style="color: #000000;">oLeft</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">nLeft</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">101</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"9.9 cm "</span> <span style="color: #0000ff;">UPDATE</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; SPINNER <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">UP</span> <span style="color: #000000;">&#40;</span> <span style="color: #000000;">0.1</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">DOWN</span> <span style="color: #000000;">&#40;</span> <span style="color: #000000;">0.1</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">MIN</span> <span style="color: #000000;">0</span> <span style="color: #0000ff;">MAX</span> <span style="color: #000000;">5</span><br /><br />&nbsp; &nbsp; <span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">GET</span> ::<span style="color: #000000;">oRight</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">nRight</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">102</span> <span style="color: #0000ff;">OF</span> oDlg ;<br /><span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"9.9 cm "</span> <span style="color: #0000ff;">UPDATE</span> ;<br />SPINNER <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">UP</span> ::<span style="color: #000000;">nRight</span> += <span style="color: #000000;">0.1</span> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">DOWN</span> ::<span style="color: #000000;">nRight</span> -= <span style="color: #000000;">0.1</span> <span style="color: #0000ff;">MIN</span> <span style="color: #000000;">0</span> <span style="color: #0000ff;">MAX</span> <span style="color: #000000;">5</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">GET</span> ::<span style="color: #000000;">oFirst</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">nFirst</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">103</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"99.9 cm "</span> <span style="color: #0000ff;">UPDATE</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; SPINNER <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">UP</span> <span style="color: #000000;">&#40;</span> <span style="color: #000000;">0.1</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">DOWN</span> <span style="color: #000000;">&#40;</span> <span style="color: #000000;">0.1</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">MIN</span> <span style="color: #000000;">-5</span> <span style="color: #0000ff;">MAX</span> <span style="color: #000000;">5</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">GET</span> ::<span style="color: #000000;">oTab</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">nTab</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">104</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"9.99 cm "</span> <span style="color: #0000ff;">UPDATE</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; SPINNER <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">UP</span> <span style="color: #000000;">&#40;</span> <span style="color: #000000;">0.01</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">DOWN</span> <span style="color: #000000;">&#40;</span> <span style="color: #000000;">0.01</span> <span style="color: #000000;">&#41;</span> <span style="color: #0000ff;">MIN</span> <span style="color: #000000;">0</span> <span style="color: #0000ff;">MAX</span> <span style="color: #000000;">5</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">COMBOBOX</span> ::<span style="color: #000000;">oAlign</span> <span style="color: #0000ff;">VAR</span> ::<span style="color: #000000;">nAlign</span> <span style="color: #0000ff;">ITEMS</span> ::<span style="color: #000000;">aAlign</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">105</span> <span style="color: #0000ff;">OF</span> oDlg<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">201</span> <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</span> lOk := .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 />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">202</span> <span style="color: #0000ff;">ACTION</span> <span style="color: #000000;">&#40;</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 />&nbsp; &nbsp;<span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTER</span></div>[/code:hqxh5mt9] the rc [code=fw:hqxh5mt9]<div class="fw" id="{CB}" style="font-family: monospace;">PARAGRAPH <span style="color: #0000ff;">DIALOG</span> <span style="color: #000000;">34</span>, <span style="color: #000000;">96</span>, <span style="color: #000000;">208</span>, <span style="color: #000000;">126</span><br /><span style="color: #0000ff;">STYLE</span> DS_MODALFRAME | 0x4L | WS_POPUP | WS_CAPTION | WS_SYSMENU<br />CAPTION <span style="color: #ff0000;">"Párrafo"</span><br /><span style="color: #0000ff;">FONT</span> <span style="color: #000000;">8</span>, <span style="color: #ff0000;">"MS Sans Serif"</span><br /><span style="color: #000000;">&#123;</span><br />&nbsp;GROUPBOX <span style="color: #ff0000;">"&Sangría"</span>, <span style="color: #000000;">-1</span>, <span style="color: #000000;">10</span>, <span style="color: #000000;">10</span>, <span style="color: #000000;">116</span>, <span style="color: #000000;">71</span>, BS_GROUPBOX | WS_GROUP<br />&nbsp;LTEXT <span style="color: #ff0000;">"I&zquierda:"</span>, <span style="color: #000000;">-1</span>, <span style="color: #000000;">21</span>, <span style="color: #000000;">23</span>, <span style="color: #000000;">45</span>, <span style="color: #000000;">9</span><br />&nbsp;EDITTEXT <span style="color: #000000;">101</span>, <span style="color: #000000;">70</span>, <span style="color: #000000;">21</span>, <span style="color: #000000;">45</span>, <span style="color: #000000;">13</span>, ES_RIGHT | WS_BORDER | WS_VSCROLL | WS_TABSTOP<br />&nbsp;LTEXT <span style="color: #ff0000;">"&Derecha:"</span>, <span style="color: #000000;">-1</span>, <span style="color: #000000;">21</span>, <span style="color: #000000;">43</span>, <span style="color: #000000;">45</span>, <span style="color: #000000;">9</span><br />&nbsp;EDITTEXT <span style="color: #000000;">102</span>, <span style="color: #000000;">70</span>, <span style="color: #000000;">41</span>, <span style="color: #000000;">45</span>, <span style="color: #000000;">13</span>, ES_RIGHT | WS_BORDER | WS_VSCROLL | WS_TABSTOP<br />&nbsp;LTEXT <span style="color: #ff0000;">"&Primera línea:"</span>, <span style="color: #000000;">-1</span>, <span style="color: #000000;">21</span>, <span style="color: #000000;">63</span>, <span style="color: #000000;">45</span>, <span style="color: #000000;">9</span><br />&nbsp;EDITTEXT <span style="color: #000000;">103</span>, <span style="color: #000000;">70</span>, <span style="color: #000000;">61</span>, <span style="color: #000000;">45</span>, <span style="color: #000000;">13</span>, ES_RIGHT | WS_BORDER | WS_VSCROLL | WS_TABSTOP<br />&nbsp;GROUPBOX <span style="color: #ff0000;">"&Tabulaciones"</span>, <span style="color: #000000;">-1</span>, <span style="color: #000000;">10</span>, <span style="color: #000000;">87</span>, <span style="color: #000000;">116</span>, <span style="color: #000000;">29</span>, BS_GROUPBOX | WS_GROUP<br />&nbsp;LTEXT <span style="color: #ff0000;">"&Espacio:"</span>, <span style="color: #000000;">-1</span>, <span style="color: #000000;">21</span>, <span style="color: #000000;">99</span>, <span style="color: #000000;">45</span>, <span style="color: #000000;">9</span><br />&nbsp;EDITTEXT <span style="color: #000000;">104</span>, <span style="color: #000000;">70</span>, <span style="color: #000000;">97</span>, <span style="color: #000000;">45</span>, <span style="color: #000000;">13</span>, ES_RIGHT | WS_BORDER | WS_VSCROLL | WS_TABSTOP<br />&nbsp;GROUPBOX <span style="color: #ff0000;">"A&lineación:"</span>, <span style="color: #000000;">-1</span>, <span style="color: #000000;">136</span>, <span style="color: #000000;">87</span>, <span style="color: #000000;">62</span>, <span style="color: #000000;">29</span>, BS_GROUPBOX | WS_GROUP<br />&nbsp;<span style="color: #0000ff;">COMBOBOX</span> <span style="color: #000000;">105</span>, <span style="color: #000000;">142</span>, <span style="color: #000000;">97</span>, <span style="color: #000000;">50</span>, <span style="color: #000000;">50</span>, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP<br />&nbsp;DEFPUSHBUTTON <span style="color: #ff0000;">"&Aceptar"</span>, <span style="color: #000000;">201</span>, <span style="color: #000000;">136</span>, <span style="color: #000000;">14</span>, <span style="color: #000000;">62</span>, <span style="color: #000000;">15</span><br />&nbsp;PUSHBUTTON <span style="color: #ff0000;">"&Cancelar"</span>, <span style="color: #000000;">202</span>, <span style="color: #000000;">136</span>, <span style="color: #000000;">36</span>, <span style="color: #000000;">62</span>, <span style="color: #000000;">15</span><br /><span style="color: #000000;">&#125;</span></div>[/code:hqxh5mt9]
problem with spinner get
Silvio, Here you have a working example: [code=fw:r7a2vnpr]<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<br /><br />&nbsp; &nbsp; <span style="color: #00C800;">LOCAL</span> nVal := <span style="color: #000000;">-1</span><br /><br />&nbsp; &nbsp; <span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg<br /><br />&nbsp; &nbsp; @ <span style="color: #000000;">1</span>,<span style="color: #000000;">1</span> <span style="color: #0000ff;">GET</span> oGet <span style="color: #0000ff;">VAR</span> nVal;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"999.9"</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; SPINNER <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">UP</span> <span style="color: #000000;">&#40;</span> nVal += <span style="color: #000000;">0.1</span>, oGet:<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 />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">DOWN</span> <span style="color: #000000;">&#40;</span> nVal -= <span style="color: #000000;">0.1</span>, oGet:<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 /><br />&nbsp; &nbsp; <span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">CENTER</span><br /><br />&nbsp; &nbsp; <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span></div>[/code:r7a2vnpr]
problem with tsbutton
I use tsbutton and I must change the bitmaps How I must make it ? I try with it but it not refresh the button can U help me [code=fw:1wpx94ts]<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;">".<span style="color: #000000;">\c</span>h<span style="color: #000000;">\T</span>sbutton.ch"</span><br /><br /><br /><span style="color: #00D7D7;">#define</span> OMBRELLONE_PRENOTATO &nbsp;<span style="color: #ff0000;">".<span style="color: #000000;">\B</span>ITMAPS<span style="color: #000000;">\O</span>MBRELLONI<span style="color: #000000;">\A</span>ZZURRO.BMP"</span><br /><span style="color: #00D7D7;">#define</span> OMBRELLONE_OCCUPATO &nbsp; &nbsp;<span style="color: #ff0000;">".<span style="color: #000000;">\B</span>ITMAPS<span style="color: #000000;">\O</span>MBRELLONI<span style="color: #000000;">\R</span>OSSO.BMP"</span><br /><span style="color: #00D7D7;">#define</span> OMBRELLONE_LIBERO &nbsp; &nbsp; <span style="color: #ff0000;">".<span style="color: #000000;">\B</span>ITMAPS<span style="color: #000000;">\O</span>MBRELLONI<span style="color: #000000;">\V</span>ERDE.BMP"</span><br /><br /><span style="color: #00D7D7;">#define</span> BMP_H &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">15</span><br /><span style="color: #00D7D7;">#define</span> BMP_V &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #000000;">15</span><br /><br /><br /><span style="color: #00C800;">static</span> oDlg<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,oBtnCat<br /><span style="color: #00C800;">Local</span> abtn<span style="color: #000000;">&#91;</span><span style="color: #000000;">3</span><span style="color: #000000;">&#93;</span><br /><span style="color: #00C800;">local</span> col:=<span style="color: #000000;">10</span><br />&nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">600</span>,<span style="color: #000000;">280</span> <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"test button"</span><br /><br /><br /><br /><span style="color: #00C800;">For</span> n=<span style="color: #000000;">1</span> <span style="color: #0000ff;">to</span> <span style="color: #000000;">3</span><br /><br />&nbsp; &nbsp;@ &nbsp;n, col &nbsp;SBUTTON aBtn<span style="color: #000000;">&#91;</span>n<span style="color: #000000;">&#93;</span>;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;FILE OMBRELLONE_PRENOTATO,;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; OMBRELLONE_OCCUPATO,;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; OMBRELLONE_PRENOTATO,;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; OMBRELLONE_PRENOTATO <span style="color: #0000ff;">PIXEL</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">OF</span> oDlg &nbsp; &nbsp;BITMAP &nbsp; &nbsp; <span style="color: #0000ff;">SIZE</span> &nbsp;BMP_H,BMP_V &nbsp; <span style="color: #0000ff;">ACTION</span> <span style="color: #0000ff;">CHANGE</span><span style="color: #000000;">&#40;</span>aBtn<span style="color: #000000;">&#41;</span><br /><br /><br /><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;col:=col<span style="color: #000000;">+30</span><br />&nbsp;<span style="color: #00C800;">next</span><br /><br /><br /><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00C800;">FOR</span> EACH oBtnCat IN aBtn<br /><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; aBtn<span style="color: #000000;">&#91;</span>n<span style="color: #000000;">&#93;</span>:<span style="color: #000000;">bAction</span>:=<span style="color: #000000;">&#123;</span> |oBtn|menupopup<span style="color: #000000;">&#40;</span> oBtn<span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00C800;">NEXT</span><br /><br /><br /><span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTER</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #00C800;">STATIC</span> <span style="color: #00C800;">FUNCTION</span> &nbsp;MENUPOPUP<span style="color: #000000;">&#40;</span> oBtn<span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00C800;">Local</span> oMenu, nRow,nCol<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #00C800;">Local</span> aRect := GetClientRect<span style="color: #000000;">&#40;</span> oBtn:<span style="color: #000000;">hWnd</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">MENU</span> oMenu POPUP &nbsp;<span style="color: #000000;">2007</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">MENUITEM</span> <span style="color: #ff0000;">"&CCUPAZIONE"</span> &nbsp; &nbsp; &nbsp; ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ACTION</span> <span style="color: #0000ff;">CHANGE</span><span style="color: #000000;">&#40;</span>oBtn<span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ENDMENU</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ACTIVATE</span> POPUP oMenu <span style="color: #00C800;">AT</span> aRect<span style="color: #000000;">&#91;</span> <span style="color: #000000;">3</span> <span style="color: #000000;">&#93;</span> + <span style="color: #000000;">1</span>, aRect<span style="color: #000000;">&#91;</span> <span style="color: #000000;">2</span> <span style="color: #000000;">&#93;</span> <span style="color: #0000ff;">OF</span> &nbsp;oBtn<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><br /><br /><br /><br /><span style="color: #00C800;">FUNCTION</span> <span style="color: #0000ff;">CHANGE</span><span style="color: #000000;">&#40;</span>oBtn<span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; oBtn:<span style="color: #000000;">ChangeBitmap</span><span style="color: #000000;">&#40;</span> <span style="color: #000000;">&#123;</span><span style="color: #000000;">1</span>,<span style="color: #000000;">2</span>,<span style="color: #000000;">3</span>,<span style="color: #000000;">4</span><span style="color: #000000;">&#125;</span>, <span style="color: #000000;">&#123;</span> OMBRELLONE_OCCUPATO,;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; OMBRELLONE_LIBERO,;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00C800;">NIL</span>,;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; OMBRELLONE_OCCUPATO <span style="color: #000000;">&#125;</span>, .t. &nbsp; <span style="color: #000000;">&#41;</span><br /><br /><br />&nbsp; &nbsp; &nbsp; oBtn:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />oDlg:<span style="color: #0000ff;">refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><br /><br /><br /><br />&nbsp;</div>[/code:1wpx94ts]
problem with xBrowse and TDatarow
Hello, I have an xBrowse with action buttons for Add, Delete, Modify, Print, etc. After adding a Record with ADO and TDataRow, despite I add oBrowse:refresh(), the browse is not refreshed: This is the code: [code=fw:25v3nkmb]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /><span style="color: #B900B9;">// ---------------------------------------------------------------------------</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oDlg &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #B900B9;">// Objeto Diálogo</span><br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oRs, oData<br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oBrowse<br /><br /><br />&nbsp; &nbsp;<span style="color: #B900B9;">//</span><br />&nbsp; &nbsp;<span style="color: #B900B9;">// RecordSet</span><br />&nbsp; &nbsp;<span style="color: #B900B9;">//-----------</span><br />&nbsp; &nbsp;oRs &nbsp; := ado_AbreRecordSet<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"select * from APUNTES order by APUNTE ASC"</span> &nbsp;<span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">IF</span> oRs = <span style="color: #00C800;">nil</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br />&nbsp; &nbsp;<span style="color: #00C800;">ENDIF</span><br /><br /><br /><br /><br /><br />&nbsp; &nbsp;<span style="color: #B900B9;">//</span><br />&nbsp; &nbsp;<span style="color: #B900B9;">// Caja de Diálogo -----------------------------------------------------</span><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">RESOURCE</span> <span style="color: #ff0000;">"APUNTES"</span> ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"Mantenimiento"</span><br /><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">XBROWSE</span> oBrowse &nbsp;<span style="color: #0000ff;">ID</span> <span style="color: #000000;">101</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; DATASOURCE oRs ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">AUTOCOLS</span> AUTOSORT CELL LINES<br /><br /><br />&nbsp; &nbsp;<span style="color: #B900B9;">// Estilo-----------</span><br />&nbsp; &nbsp;oBrowse:<span style="color: #000000;">nMarqueeStyle</span> &nbsp; &nbsp; &nbsp; := <span style="color: #000000;">5</span> <span style="color: #B900B9;">//9 // 5 por defecto MARQSTYLE_IDESOFT</span><br />&nbsp; &nbsp;oBrowse:<span style="color: #000000;">nHeaderLines</span> &nbsp; &nbsp; &nbsp; &nbsp;:= <span style="color: #000000;">1.5</span><br />&nbsp; &nbsp;oBrowse:<span style="color: #000000;">nStretchCol</span> &nbsp; &nbsp; &nbsp; &nbsp; := STRETCHCOL_LAST<br />&nbsp; &nbsp;oBrowse:<span style="color: #000000;">lAllowColHiding</span> &nbsp; &nbsp; := .F. &nbsp; <span style="color: #B900B9;">// Impedir tocar columnas</span><br /><br /><br />&nbsp; &nbsp;oBrowse:<span style="color: #000000;">blDblClick</span> := <span style="color: #000000;">&#123;</span> || <span style="color: #000000;">&#40;</span> &nbsp;AltasApuntes<span style="color: #000000;">&#40;</span> .F., oRs:<span style="color: #000000;">AbsolutePosition</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span><br />&nbsp; &nbsp;oBrowse:<span style="color: #000000;">bKeyDown</span> := <span style="color: #000000;">&#123;</span> | nKey, nFlags | <span style="color: #00C800;">IF</span> <span style="color: #000000;">&#40;</span>nKey==VK_RETURN, 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 />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #00C800;">IF</span> <span style="color: #000000;">&#40;</span>nKey==VK_ESCAPE, 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;">&#125;</span><br /><br /><br /><br /><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">711</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</span> AltasApuntes<span style="color: #000000;">&#40;</span> .T. <span style="color: #000000;">&#41;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; oBrowse:<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 /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">712</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</span> ado_Borrar<span style="color: #000000;">&#40;</span> oRs <span style="color: #000000;">&#41;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; oBrowse:<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 /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">713</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</span> AltasApuntes<span style="color: #000000;">&#40;</span> .F., oRs:<span style="color: #000000;">AbsolutePosition</span> <span style="color: #000000;">&#41;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; oBrowse:<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 /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">716</span> <span style="color: #0000ff;">OF</span> oDlg <span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</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 /><br /><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTERED</span> <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">INIT</span> oBrowse:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br /><br />&nbsp; &nbsp;ado_CierraRecordSet<span style="color: #000000;">&#40;</span> oRs <span style="color: #000000;">&#41;</span><br /><br /><br /><br /><span style="color: #B900B9;">// ---------------------------------------------------------------------------</span><br /><span style="color: #00C800;">FUNCTION</span> AltasApuntes<span style="color: #000000;">&#40;</span> lAppend, nRegistro <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oDlg &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #B900B9;">// Objeto Diálogo</span><br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> oRs, oData<br />&nbsp; &nbsp;<span style="color: #00C800;">LOCAL</span> lSave &nbsp; &nbsp; &nbsp; := .F. &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #B900B9;">// Grabado</span><br /><br /><br /><br /><br />&nbsp; &nbsp;<span style="color: #B900B9;">//</span><br />&nbsp; &nbsp;<span style="color: #B900B9;">// Seleccionamos RecordSet</span><br />&nbsp; &nbsp;<span style="color: #B900B9;">//-------------------------</span><br />&nbsp; &nbsp;oRs &nbsp; := ado_AbreRecordSet<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"select * from APUNTES order by APUNTE ASC"</span> &nbsp;<span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">IF</span> oRs = <span style="color: #00C800;">nil</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br />&nbsp; &nbsp;<span style="color: #00C800;">ENDIF</span><br /><br /><br /><br /><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">IF</span> lAppend &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #B900B9;">// Si hay que a¤adir</span><br />&nbsp; &nbsp; &nbsp; oData := TDataRow<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">&#40;</span> oRs, <span style="color: #00C800;">nil</span>, .t. <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; oData:<span style="color: #000000;">Fecha</span> := Date<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">ELSE</span><br />&nbsp; &nbsp; &nbsp; oRs:<span style="color: #000000;">AbsolutePosition</span> := nRegistro &nbsp;<span style="color: #B900B9;">// Goto</span><br />&nbsp; &nbsp; &nbsp; oData := TDataRow<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">&#40;</span> oRs <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">ENDIF</span><br /><br /><br /><span style="color: #000000;">&#91;</span>...<span style="color: #000000;">&#93;</span><br /><br /><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">GET</span> oData:<span style="color: #000000;">Fecha</span> &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">ID</span> &nbsp;<span style="color: #000000;">20</span> <span style="color: #0000ff;">OF</span> oDlg &nbsp;<span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@D"</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">GET</span> oData:<span style="color: #000000;">Cuenta</span> &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ID</span> &nbsp;<span style="color: #000000;">21</span> <span style="color: #0000ff;">OF</span> oDlg &nbsp;<span style="color: #0000ff;">PICTURE</span> <span style="color: #ff0000;">"@E 9999"</span><br /><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">701</span> <span style="color: #0000ff;">OF</span> oDlg &nbsp;<span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</span> lSave := .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 />&nbsp; &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">702</span> <span style="color: #0000ff;">OF</span> oDlg &nbsp;<span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</span> lSave := .F., 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 /><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 /><br /><br /><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">IF</span> lSave <span style="color: #B900B9;">// .AND. !Empty( oData:cCuenta ) .AND. !cDebeHaber = "Seleccione"</span><br />&nbsp; &nbsp; &nbsp; oData:<span style="color: #000000;">Save</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">ENDIF</span><br />&nbsp; &nbsp;<span style="color: #B900B9;">// ---------------------------------------------------------------------</span><br /><br /><br /><br /><br />&nbsp; &nbsp;ado_CierraRecordSet<span style="color: #000000;">&#40;</span> oRs <span style="color: #000000;">&#41;</span><br /><br /><br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">NIL</span><br /><span style="color: #B900B9;">// ---------------------------------------------------------------------------</span><br /><br /><br /><br /><br />&nbsp;</div>[/code:25v3nkmb] Anything else has to be done for ADO?. Thank you. Best regards-.
problem with xBrowse and TDatarow
Please first build the sample below and test. You see that same code of XBrowse and TDataRow works for DBF, TDatabase and ADO. You can test all options. [code=fw:3h0cgisy]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #B900B9;">/*<br />* tstdrow.prg<br />* test TDataRow usage<br />*<br />*/</span><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;">"xbrowse.ch"</span><br /><br />REQUEST DBFCDX<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 />&nbsp; &nbsp;<span style="color: #00C800;">local</span> oCn<br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> nChoice, uDataSource<br /><br />&nbsp; &nbsp;SET DATE ITALIAN<br />&nbsp; &nbsp;SET CENTURY <span style="color: #0000ff;">ON</span><br />&nbsp; &nbsp;SET DELETED <span style="color: #0000ff;">ON</span><br />&nbsp; &nbsp;FWNumFormat<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"A"</span>, .t. <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;nChoice := Alert<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"Choose DataSource"</span>, <span style="color: #000000;">&#123;</span> <span style="color: #ff0000;">"DBF"</span>, <span style="color: #ff0000;">"TDATABASE"</span>, <span style="color: #ff0000;">"ADO"</span>, <span style="color: #ff0000;">"Quit"</span> <span style="color: #000000;">&#125;</span>, <span style="color: #ff0000;">"DATASOURCE"</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">if</span> nChoice &nbsp;<= <span style="color: #000000;">2</span><br />&nbsp; &nbsp; &nbsp; USE C:\FWH\SAMPLES\CUSTOMER <span style="color: #00C800;">NEW</span> <span style="color: #0000ff;">ALIAS</span> CUST SHARED VIA <span style="color: #ff0000;">"DBFCDX"</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">if</span> nChoice == <span style="color: #000000;">1</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;uDataSource &nbsp; &nbsp;:= <span style="color: #0000ff;">Alias</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">else</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;DATABASE uDataSource<br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">endif</span><br />&nbsp; &nbsp;elseif nChoice == <span style="color: #000000;">3</span><br />&nbsp; &nbsp; &nbsp; oCn &nbsp; &nbsp; &nbsp; &nbsp; := FW_OpenAdoConnection<span style="color: #000000;">&#40;</span> <span style="color: #ff0000;">"c:<span style="color: #000000;">\f</span>wh<span style="color: #000000;">\s</span>amples<span style="color: #000000;">\x</span>brtest.mdb"</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; uDataSource := FW_OpenRecordSet<span style="color: #000000;">&#40;</span> oCn, <span style="color: #ff0000;">"CUSTOMER"</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">else</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br />&nbsp; &nbsp;<span style="color: #00C800;">endif</span><br /><br />&nbsp; &nbsp;BrowseData<span style="color: #000000;">&#40;</span> uDataSource <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">if</span> nChoice == <span style="color: #000000;">1</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#40;</span> uDataSource <span style="color: #000000;">&#41;</span>-><span style="color: #000000;">&#40;</span> DbCloseArea<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;<span style="color: #00C800;">else</span><br />&nbsp; &nbsp; &nbsp; uDataSource:<span style="color: #000000;">Close</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">if</span> oCn != <span style="color: #00C800;">nil</span><br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;oCn:<span style="color: #000000;">Close</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp; &nbsp; <span style="color: #00C800;">endif</span><br />&nbsp; &nbsp;<span style="color: #00C800;">endif</span><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><span style="color: #B900B9;">// TESTING XBROWSE WITH TDATAROW</span><br /><span style="color: #B900B9;">// Both XBrowse and TDataRow Code is the same for all Data Sources</span><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br /><br /><span style="color: #00C800;">static</span> <span style="color: #00C800;">function</span> BrowseData<span style="color: #000000;">&#40;</span> uData <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #00C800;">local</span> oDlg, oBrw, oFont, oRec<br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">DEFINE</span> <span style="color: #0000ff;">FONT</span> oFont <span style="color: #0000ff;">NAME</span> <span style="color: #ff0000;">"TAHOMA"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">0</span>,<span style="color: #000000;">-14</span><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;">900</span>,<span style="color: #000000;">400</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">FONT</span> oFont ;<br />&nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">TITLE</span> <span style="color: #ff0000;">"TDataRow test : "</span> + FWVERSION<br />&nbsp; &nbsp;@ <span style="color: #000000;">30</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">XBROWSE</span> oBrw <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">-10</span>,<span style="color: #000000;">-10</span> <span style="color: #0000ff;">PIXEL</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; DATASOURCE uData <span style="color: #0000ff;">AUTOCOLS</span> AUTOSORT ;<br />&nbsp; &nbsp; &nbsp; FOOTERS CELL LINES NOBORDER<br /><br />&nbsp; &nbsp;WITH OBJECT oBrw<br />&nbsp; &nbsp; &nbsp; <span style="color: #B900B9;">//</span><br />&nbsp; &nbsp; &nbsp; :<span style="color: #000000;">CreateFromCode</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />&nbsp; &nbsp;END<br /><br />&nbsp; &nbsp;@ <span style="color: #000000;">10</span>,<span style="color: #000000;">10</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #ff0000;">"Edit"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">40</span>,<span style="color: #000000;">12</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: #000000;">&#40;</span> oRec := TDataRow<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">&#40;</span> uData <span style="color: #000000;">&#41;</span>, oRec:<span style="color: #00C800;">Edit</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBrw:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBrw:<span style="color: #000000;">SetFocus</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: #000000;">10</span>,<span style="color: #000000;">60</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #ff0000;">"Append"</span> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">40</span>,<span style="color: #000000;">12</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: #000000;">&#40;</span> oRec := TDataRow<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">&#40;</span> uData, <span style="color: #00C800;">nil</span>, .t. <span style="color: #000000;">&#41;</span>, oRec:<span style="color: #00C800;">Edit</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBrw:<span style="color: #0000ff;">Refresh</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>, oBrw:<span style="color: #000000;">SetFocus</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span><br /><br />&nbsp; &nbsp;<span style="color: #0000ff;">ACTIVATE</span> <span style="color: #0000ff;">DIALOG</span> oDlg <span style="color: #0000ff;">CENTERED</span><br />&nbsp; &nbsp;<span style="color: #0000ff;">RELEASE</span> <span style="color: #0000ff;">FONT</span> oFont<br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><br /><span style="color: #B900B9;">//----------------------------------------------------------------------------//</span><br />&nbsp;</div>[/code:3h0cgisy]
problem with xBrowse and TDatarow
Mr. Nages, I sent you a full working example. Did you were able to test it, please?. I also discovered: Mr. Nages, I am sorry to disturb you, but I have found several errors with xBrowse, DataRow and ADO. Please, see sample attached. First, after adding a new record with "Añadir" option, the xBrowse is not refresed despite the call oBrowse:Refresh(), and the new record is not shown: [code=fw:inbqhfv6]<div class="fw" id="{CB}" style="font-family: monospace;"> &nbsp;<span style="color: #0000ff;">REDEFINE</span> <span style="color: #0000ff;">BUTTON</span> <span style="color: #0000ff;">ID</span> <span style="color: #000000;">711</span> <span style="color: #0000ff;">OF</span> oDlg ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">ACTION</span><span style="color: #000000;">&#40;</span> AltasApuntes<span style="color: #000000;">&#40;</span> .T. <span style="color: #000000;">&#41;</span>, ;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; oBrowse:<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 /><br />&nbsp;</div>[/code:inbqhfv6] Also, when we succeed in refreshing, I would like to set the xBrowse on the new row added. In DBFS it is done automatically. Second, the same happens with Modificar (Modify) option. Also, if I click on header and I change the short method of the column, oRs:AbsolutePosition is not updated, at: [code=fw:inbqhfv6]<div class="fw" id="{CB}" style="font-family: monospace;"> &nbsp; oBrowse:<span style="color: #000000;">blDblClick</span> := <span style="color: #000000;">&#123;</span> || <span style="color: #000000;">&#40;</span> &nbsp;AltasApuntes<span style="color: #000000;">&#40;</span> .F., oRs:<span style="color: #000000;">AbsolutePosition</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#125;</span> &nbsp;</div>[/code:inbqhfv6] Thank you. Best regards
problem with xBrowse and TDatarow
Mr Lucas I shall go through your code. Meanwhile please build and test the code posted by me. Let me know if you find any problem there. I shall respond to your code a little while later