FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin para Harbour/xHarbour ¿Cómo reemplazar funcion en libreria?
Posts: 2170
Joined: Fri Jul 18, 2008 01:24 AM
¿Cómo reemplazar funcion en libreria?
Posted: Sun Mar 01, 2009 10:04 PM

Específicamente lo que quiero hacer es reemplazar la Classe Tcombobox en la libreria de Fivehx por una modificada.
He leído la ayuda de BCC55 y utilizado el programa Elib.exe para ver las funciones en la libreria de Fivehx, pero la que encuentra es DBCombo y no Combobox. Entonces, ¿Cómo puedo hacer para reemplazar la Classe Tcombobox?
Gracias de antemano.

Saludos

Francisco J. Alegría P.

Chinandega, Nicaragua.



Fwxh-MySql-TMySql
Posts: 1335
Joined: Fri Jun 13, 2008 11:04 AM
Re: ¿Cómo reemplazar funcion en libreria?
Posted: Mon Mar 02, 2009 04:48 AM
Estimado Mr.Francisco,

Prueba esto para Harbour

Code (fw): Select all Collapse
@ECHO OFF
CLS
set hdir=d:\harbour
set bcdir=d:\bcc55\bin

%hdir%\bin\harbour COMBOBOX.PRG /n /id:\fwh\include;%hdir%\include /oCOMBOBOX.C
%bcdir%\bcc32 -M -c -D__HARBOUR__ -I%hdir%\include  -oCOMBOBOX.OBJ  COMBOBOX.C

%bcdir%\tlib d:\fwh\lib\fiveh.lib + COMBOBOX.OBJ


Por favor, háganos saber el resultado.

Mr.Antonio,

¿Cuál sería el equivalente para las banderas xHarbour? ¿Será lo mismo?
Code (fw): Select all Collapse
%bcdir%\bcc32 -M -c -D__HARBOUR__ -I%hdir%\include  -oCOMBOBOX.OBJ  COMBOBOX.C


Saludos

Anser
Posts: 2170
Joined: Fri Jul 18, 2008 01:24 AM
Re: ¿Cómo reemplazar funcion en libreria?
Posted: Mon Mar 02, 2009 01:47 PM

Anser, gracias por tu respuesta. Me diste la guía para lograrlo y quedó así:

@ECHO OFF
CLS
set hdir=C:\xharbour712
set bcdir=C:\bcc55\bin
set fwhdir=C:\FWH712

%hdir%\bin\harbour COMBOBOX.PRG /n /i%fwhdir%\include;%hdir%\include /oCOMBOBOX.C
%bcdir%\bcc32 -M -c -D__HARBOUR__ -I%hdir%\include -oCOMBOBOX.OBJ COMBOBOX.C

%bcdir%\tlib %fwhdir%\lib\fivehx.lib -+ COMBOBOX.OBJ

@del %fwhdir%\LIB\fivehx.BAK
@del combobox.c
@del combobox.obj

NOTA: El .Bat lo corro dentro de \Fwh712\source\classes
Saludos.

Francisco J. Alegría P.

Chinandega, Nicaragua.



Fwxh-MySql-TMySql
Posts: 1074
Joined: Fri Oct 07, 2005 01:56 PM
Re: ¿Cómo reemplazar funcion en libreria?
Posted: Mon Mar 02, 2009 02:22 PM
Code (fw): Select all Collapse
del FIVEH.LOG

ECHO Classes  -COMBOBOX
c:\xharbour\bin\harbour.exe c:\fwh\source\classes\COMBOBOX /n /a /w /es1 /ic:\fwh\include;c:\xharbour\include > FIVEH.LOG
if errorlevel 1 echo error de compilacion >> FIVEH.LOG
ECHO -O2 -Ic:\xharbour\include -tW COMBOBOX.C > b32.bc
c:\borland\bcc55\bin\bcc32.exe -tWM -DHB_GUI -DHB_API_MACROS -DHB_STACK_MACROS -DHB_FM_STATISTICS_OFF -d -a8 -OS -O2 -5 -c @b32.bc >> FIVEH.LOG
c:\borland\bcc55\bin\tlib.exe fivehX -+COMBOBOX >> FIVEH.LOG

DEL COMBOBOX.C >> FIVEH.LOG
DEL COMBOBOX.OBJ >> FIVEH.LOG

goto end
:error
echo error de compilacion >> FIVEH.LOG
notepad FIVEH.LOG

:end
PAUSE
Saludos
Patricio

__________________________________________________________________
Version: Harbour 3.2.0dev (r1307082134),Compiler: Borland C++ 5.8.2 (32-bit)
PCode version: 0.3, FWH 13.2
http://www.sialm.cl
Posts: 2170
Joined: Fri Jul 18, 2008 01:24 AM
Re: ¿Cómo reemplazar funcion en libreria?
Posted: Mon Mar 02, 2009 03:47 PM

Patricio... gracias.

Saludos.

Francisco J. Alegría P.

Chinandega, Nicaragua.



Fwxh-MySql-TMySql
Posts: 1335
Joined: Fri Jun 13, 2008 11:04 AM
Re: ¿Cómo reemplazar funcion en libreria?
Posted: Tue Mar 03, 2009 06:05 AM
Estimado Francisco y Patricio,

Muchas gracias por sus respuestas.

Me pregunto acerca de las banderas utilizadas durante la compilación de código C utilizando bcc32.exe

Como por la respuesta de Francisco Yo entiendo que el mismo banderas se pueden utilizar para crear el archivo obj para Harbour y xHarbour utilizando bcc32.exe

Pero como la muestra de Patricio por las banderas son totalmente diferentes y estoy confundido acerca de las diferencias

Harbour y xHarbour as per Francisco

Code (fw): Select all Collapse
%bcdir%\bcc32 -M -c -D__HARBOUR__ -I%hdir%\include -oCOMBOBOX.OBJ COMBOBOX.C


As per Patricio

Code (fw): Select all Collapse
c:\borland\bcc55\bin\bcc32.exe -tWM -DHB_GUI -DHB_API_MACROS -DHB_STACK_MACROS -DHB_FM_STATISTICS_OFF -d -a8 -OS -O2 -5 -c @b32.bc >> FIVEH.LOG


Gracias

Anser
Posts: 2170
Joined: Fri Jul 18, 2008 01:24 AM
Re: ¿Cómo reemplazar funcion en libreria?
Posted: Tue Mar 03, 2009 12:39 PM

Anser: Esta es la version que utilizo.

C:\BCC55\Bin>bcc32
Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
Syntax is: BCC32 [ options ] file[s] * = default; -x- = turn switch x off
-3 * 80386 Instructions -4 80486 Instructions
-5 Pentium Instructions -6 Pentium Pro Instructions
-Ax Disable extensions -B Compile via assembly
-C Allow nested comments -Dxxx Define macro
-Exxx Alternate Assembler name -Hxxx Use pre-compiled headers
-Ixxx Include files directory -K Default char is unsigned
-Lxxx Libraries directory -M Generate link map
-N Check stack overflow -Ox Optimizations
-P Force C++ compile -R Produce browser info
-RT * Generate RTTI -S Produce assembly output
-Txxx Set assembler option -Uxxx Undefine macro
-Vx Virtual table control -X Suppress autodep. output
-aN Align on N bytes -b * Treat enums as integers
-c Compile only -d Merge duplicate strings
-exxx Executable file name -fxx Floating point options
-gN Stop after N warnings -iN Max. identifier length
-jN Stop after N errors -k * Standard stack frame
-lx Set linker option -nxxx Output file directory
-oxxx Object file name -p Pascal calls
-tWxxx Create Windows app -u * Underscores on externs
-v Source level debugging -wxxx Warning control
-xxxx Exception handling -y Produce line number info
-zxxx Set segment names

C:\BCC55\Bin> tlib
TLIB 4.5 Copyright (c) 1987, 1999 Inprise Corporation
Syntax: TLIB libname [/C] [/E] [/P] [/0] commands, listfile
libname library file pathname
commands sequence of operations to be performed (optional)
listfile file name for listing file (optional)

A command is of the form: <symbol>modulename, where <symbol> is:
+ add modulename to the library
- remove modulename from the library
* extract modulename without removing it
-+ or +- replace modulename in library
- or - extract modulename and remove it

/C          case-sensitive library
/PSIZE      set the library page size to SIZE
/0          purge comment records

Use @filepath to continue from file "filepath".
Use '&' at end of a line to continue onto the next line.

Saludos.

Francisco J. Alegría P.

Chinandega, Nicaragua.



Fwxh-MySql-TMySql
Posts: 1335
Joined: Fri Jun 13, 2008 11:04 AM
Re: ¿Cómo reemplazar funcion en libreria?
Posted: Tue Mar 03, 2009 01:37 PM

Francisco,

Gracias
Anser

Continue the discussion