wbrowse de FWH

wbrowse de FWH

Postby pymsoft » Wed Jul 18, 2007 4:14 pm

Hay algun motivo por el cual la funcion wbrwline usada por la clase twbrowse no sea la escrita en lenguaje C?
Porque en el caso de Clipper se usa esa funcion en C.
Luego de hacer varias pruebas, vi que es la funcion que demora mas tiempo cuando se hace uso intensivo de wbrowse, y usando el mismo programa, pero compilado con clipper, la visualizacion del browse es muchisimo mas rapida, sobretodo cuando se usa con varios terminales trabajando en red.

Saludos
Pedro Gonzalez
User avatar
pymsoft
 
Posts: 383
Joined: Tue Oct 11, 2005 1:01 pm
Location: Savona - Italia

Postby Antonio Linares » Wed Jul 18, 2007 4:38 pm

Pedro,

Cuando se diseñó wbrwline() los ordenadores que había en uso eran mucho menos potentes que ahora y necesitabamos el código más rápido.

Hoy en día podemos usar esa función implementada en PRG. De todas formas si necesitas la máxima velocidad, entonces si podrías usar la versión en lenguaje C
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41947
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby pymsoft » Thu Jul 19, 2007 7:30 am

Antonio,

hay alguna diferencia aparte de la velocidad?
En mi caso la velocidad es importante, porque como dije antes, cuando uso las bases de datos, sea en un servidor windows o linux, si accedo desde un unico pc, el browse vuela, pero cuando accedo desde 2 o mas pc's, se enlentece muchisimo, es posible que sea un problema en la dbfcdx...
Hasta hace un par de semanas usaba el browse de Hernán, lo cambié por el browse de FW porque el de FW es mas rapido, y lo unico que puedo hacer son los footers, y la multiseleccion, pero lo demas sin problemas.
Noté que el browse a 16 bits funciona mas rapido que el de 32, pero como dije antes, podría ser un problema de la DBFCDX.

Probaré entonces la wbrwline en C a ver que resultados obtengo.

Saludos y gracias.
Pedro Gonzalez
User avatar
pymsoft
 
Posts: 383
Joined: Tue Oct 11, 2005 1:01 pm
Location: Savona - Italia

Postby pymsoft » Thu Jul 19, 2007 10:06 am

Antonio,


No me resultó tan facil usar la wbrwline contenida en wbrwline.c

Pensé que bastaba poner #ifndef __CLIPPER__ donde tiene #ifdef
y en wbrowse.prg al reves... pero al compilar me da estos errores:

Code: Select all  Expand view

Progetto: WP32, Ambiente: BorlandWin:
[1]:Harbour.Exe wbrowse.prg  /m /n0 /w1 /es2 /ic:\ut\fwh0705\include /iC:\XHXFW0~1\Include /p /oObj\wbrowse.c
xHarbour Compiler build 0.99.71 (SimpLex)
Copyright 1999-2007, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'wbrowse.prg' and generating preprocessed output to 'wbrowse.ppo'...
Lines 2565, Functions/Procedures 52
Generating C source output to 'Obj\wbrowse.c'...
Done.
[1]:Bcc32.Exe -M -c -O2  -tW -v- -X  -DHB_FM_STATISTICS_OFF -DHB_NO_DEFAULT_API_MACROS -DHB_NO_DEFAULT_STACK_MACROS -DHB_OS_WIN_32 -Ic:\ut\fwh0705\include -IC:\BCC55\Include;C:\XHXFW0~1\Include  -nObj Obj\wbrowse.c
Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
Obj\WBROWSE.c:
[1]:Bcc32.Exe -M -c -O2  -tW -v- -X  -DHB_FM_STATISTICS_OFF -DHB_NO_DEFAULT_API_MACROS -DHB_NO_DEFAULT_STACK_MACROS -DHB_OS_WIN_32 -Ic:\ut\fwh0705\include -IC:\BCC55\Include;C:\XHXFW0~1\Include  -nObj -D__HARBOUR__ wbrwline.c
Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
wbrwline.c:
Warning W8065 wbrwline.c 181: Call to function '_VARRAYLEN' with no prototype in function PaintTheLine
Error E2451 wbrwline.c 183: Undefined symbol 'CLV_WORD' in function PaintTheLine
Error E2379 wbrwline.c 183: Statement missing ; in function PaintTheLine
Error E2140 wbrwline.c 184: Declaration is not allowed here in function PaintTheLine
Error E2140 wbrwline.c 185: Declaration is not allowed here in function PaintTheLine
Error E2140 wbrwline.c 186: Declaration is not allowed here in function PaintTheLine
Error E2140 wbrwline.c 187: Declaration is not allowed here in function PaintTheLine
Error E2451 wbrwline.c 204: Undefined symbol '_tos' in function PaintTheLine
Warning W8065 wbrwline.c 204: Call to function '_cAt' with no prototype in function PaintTheLine
Error E2451 wbrwline.c 219: Undefined symbol 'S_ANYNUM' in function PaintTheLine
Warning W8065 wbrwline.c 255: Call to function '_VARRAYLEN' with no prototype in function PaintTheLine
Error E2451 wbrwline.c 257: Undefined symbol 'lJustify' in function PaintTheLine
Warning W8065 wbrwline.c 257: Call to function '_cAt' with no prototype in function PaintTheLine
Error E2451 wbrwline.c 262: Undefined symbol 'S_CHAR' in function PaintTheLine
Warning W8065 wbrwline.c 262: Call to function '_VSTR' with no prototype in function PaintTheLine
Warning W8069 wbrwline.c 262: Nonportable pointer conversion in function PaintTheLine
Warning W8065 wbrwline.c 269: Call to function '_VSTR' with no prototype in function PaintTheLine
Warning W8069 wbrwline.c 269: Nonportable pointer conversion in function PaintTheLine
Warning W8065 wbrwline.c 277: Call to function '_VSTR' with no prototype in function PaintTheLine
Warning W8069 wbrwline.c 277: Nonportable pointer conversion in function PaintTheLine
Warning W8065 wbrwline.c 282: Call to function '_VSTR' with no prototype in function PaintTheLine
Warning W8069 wbrwline.c 282: Nonportable pointer conversion in function PaintTheLine
Warning W8065 wbrwline.c 491: Call to function '_cEval0' with no prototype in function WBRWLINE
Warning W8065 wbrwline.c 503: Call to function '_cEval0' with no prototype in function WBRWLINE
Warning W8004 wbrwline.c 685: 'paSizes' is assigned a value that is never used in function ABRWPOSRECT
*** 10 errors in Compile ***


que me falta hacer?

Gracias
Pedro Gonzalez
User avatar
pymsoft
 
Posts: 383
Joined: Tue Oct 11, 2005 1:01 pm
Location: Savona - Italia

Postby Antonio Linares » Thu Jul 19, 2007 11:19 am

Pedro,

No es tan simple ya que ese código está diseñado para Clipper y no para Harbour

Se podría adaptar para Harbour pero no son cambios inmediatos y sencillos
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41947
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby pymsoft » Thu Jul 19, 2007 12:11 pm

Antonio,

Entiendo.
Pedro Gonzalez
User avatar
pymsoft
 
Posts: 383
Joined: Tue Oct 11, 2005 1:01 pm
Location: Savona - Italia


Return to FiveWin para Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 64 guests