Hola a todos,
Hace mucho que no me logono en este foro, pero os voy leyendo con ganas.
El caso es que deseo actualizar mi vieja versi贸n de FWH y en mi aplicaci贸n hago uso de la maravillosa clase TDbf de Manu Exp贸sito (una versi贸n antigua en PRG).
Esta clase la tengo en las entra帽as y por todos lados de la aplicaci贸n y uno de los ficheros que usa tiene este c贸digo en C:
El caso es que necesito de una alma caritativa que intente compilar este c贸digo con BCC a 64b para ver por donde cruje y que soluci贸n se le puede dar.
Si salvo este obst谩culo podr茅 evolucionar junto a FWH, si no quedar茅 atr谩s con los 32b.
Deseo actualizarme. FWH evoluciona sin prisa pero sin pausa. Me gusta.
Muchas gracias,
Hace mucho que no me logono en este foro, pero os voy leyendo con ganas.
El caso es que deseo actualizar mi vieja versi贸n de FWH y en mi aplicaci贸n hago uso de la maravillosa clase TDbf de Manu Exp贸sito (una versi贸n antigua en PRG).
Esta clase la tengo en las entra帽as y por todos lados de la aplicaci贸n y uno de los ficheros que usa tiene este c贸digo en C:
//----------------------------------------------------------------------------//
// 聽AUTOR.....: Manuel Exp垄sito Su聽rez 聽 聽Soft 4U '1994-2000 聽 聽 聽 聽 聽 聽 聽 聽 聽//
// 聽e-Mail....: <!-- e --><a href="mailto:expo2001@wanadoo.es">expo2001@wanadoo.es</a><!-- e --> 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 //
// 聽CLASE.....: HBFORCE.C 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 //
// 聽FECHA MOD.: 10/11/2000 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽//
// 聽VERSION...: 9.00 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽//
// 聽PROPOSITO.: Accesos a bajo nivel a la estructura WorkArea de Harbour 聽 聽 聽//
//----------------------------------------------------------------------------//
//----------------------------------------------------------------------------//
//Para las RDD nativas de Harbour
#include "hbrdddbf.h"
#include "hbapirdd.h"
//----------------------------------------------------------------------------//
HB_FUNC( DBFHDL )
{
聽 聽LPDBFAREA pArea = hb_rddGetCurrentWorkAreaPointer();
聽 聽if( pArea )
聽 聽// Con la nueva versi贸n de Harbour (9.02), y el cambio del 'valor' hDataFile
聽 聽// por pDataFile en la estructura _DBFAREA de HbRddDbf.h, esta funci贸n no es
聽 聽// correcta y debe cambiarse por hb_retptr().
聽 聽//
聽 聽// hb_retni( pArea->hDataFile );
聽 聽//else
聽 聽// 聽 hb_retni( 0 );
聽 聽 聽 hb_retptr( pArea->pDataFile );
聽 聽else
聽 聽 聽 hb_retptr( 0 );
}
//----------------------------------------------------------------------------//
HB_FUNC( ISSHARED )
{
聽 聽LPDBFAREA pArea = hb_rddGetCurrentWorkAreaPointer();
聽 聽if( pArea )
聽 聽 聽 hb_retl( pArea->fShared );
聽 聽else
聽 聽 聽 hb_retl( HB_FALSE );
}
//----------------------------------------------------------------------------//
HB_FUNC( ISREADONLY )
{
聽 聽LPDBFAREA pArea = hb_rddGetCurrentWorkAreaPointer();
聽 聽if( pArea )
聽 聽 聽 hb_retl( pArea->fReadonly );
聽 聽else
聽 聽 聽 hb_retl( HB_FALSE );
}
//----------------------------------------------------------------------------//
// Para la RDD ADS de Harbour
// Extraido de rddads.h
typedef unsigned long 聽ADSHANDLE;
typedef struct _ADSAREA_
{
聽 聽struct _RDDFUNCS * lprfsHost; /* Virtual method table for this workarea */
聽 聽HB_USHORT uiArea; 聽 聽 聽 聽 聽 聽 聽 聽/* The number assigned to this workarea */
聽 聽void * atomAlias; 聽 聽 聽 聽 聽 聽 /* Pointer to the alias symbol for this workarea */
聽 聽HB_USHORT uiFieldExtent; 聽 聽 聽 聽 /* Total number of fields allocated */
聽 聽HB_USHORT uiFieldCount; 聽 聽 聽 聽 聽/* Total number of fields used */
聽 聽LPFIELD lpFields; 聽 聽 聽 聽 聽 聽 /* Pointer to an array of fields */
聽 聽void * lpFieldExtents; 聽 聽 聽 聽/* Void ptr for additional field properties */
聽 聽PHB_ITEM valResult; 聽 聽 聽 聽 聽 /* All purpose result holder */
聽 聽HB_BOOL fTop; 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽/* TRUE if "top" */
聽 聽HB_BOOL fBottom; 聽 聽 聽 聽 聽 聽 聽 聽 /* TRUE if "bottom" */
聽 聽HB_BOOL fBof; 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽/* TRUE if "bof" */
聽 聽HB_BOOL fEof; 聽 聽 聽 聽 聽 聽 聽 聽 聽 聽/* TRUE if "eof" */
聽 聽HB_BOOL fFound; 聽 聽 聽 聽 聽 聽 聽 聽 聽/* TRUE if "found" */
聽 聽DBSCOPEINFO dbsi; 聽 聽 聽 聽 聽 聽 /* Info regarding last LOCATE */
聽 聽DBFILTERINFO dbfi; 聽 聽 聽 聽 聽 聽/* Filter in effect */
聽 聽LPDBORDERCONDINFO lpdbOrdCondInfo;
聽 聽LPDBRELINFO lpdbRelations; 聽 聽/* Parent/Child relationships used */
聽 聽HB_USHORT uiParents; 聽 聽 聽 聽 聽 聽 /* Number of parents for this area */
聽 聽HB_USHORT heap;
聽 聽HB_USHORT heapSize;
聽 聽HB_USHORT rddID;
聽 聽/*
聽 聽* 聽ADS's additions to the workarea structure
聽 聽*
聽 聽* 聽Warning: The above section MUST match WORKAREA exactly! 聽Any
聽 聽* 聽additions to the structure MUST be added below, as in this
聽 聽* 聽example.
聽 聽*/
聽 聽char * szDataFileName; 聽 聽 聽 聽/* Name of data file */
聽 聽HB_USHORT uiHeaderLen; 聽 聽 聽 聽 聽 /* Size of header */
聽 聽HB_USHORT uiRecordLen; 聽 聽 聽 聽 聽 /* Size of record */
聽 聽HB_ULONG ulRecCount; 聽 聽 聽 聽 聽 聽 /* Total records */
聽 聽HB_ULONG ulRecNo; 聽 聽 聽 聽 聽 聽 聽 聽/* Current record */
聽 聽HB_BYTE bYear; 聽 聽 聽 聽 聽 聽 聽 聽 聽 /* Last update */
聽 聽HB_BYTE bMonth;
聽 聽HB_BYTE bDay;
聽 聽HB_USHORT * pFieldOffset; 聽 聽 聽 聽/* Pointer to field offset array */
聽 聽HB_BYTE * pRecord; 聽 聽 聽 聽 聽 聽 聽 /* Buffer of record data */
聽 聽HB_ULONG maxFieldLen;
聽 聽HB_BOOL fValidBuffer; 聽 聽 聽 聽 聽 聽/* State of buffer */
聽 聽HB_BOOL fRecordChanged; 聽 聽 聽 聽 聽/* Record changed */
聽 聽HB_BOOL fShared; 聽 聽 聽 聽 聽 聽 聽 聽 /* Shared file */
聽 聽HB_BOOL fReadonly; 聽 聽 聽 聽 聽 聽 聽 /* Read only file */
聽 聽HB_BOOL fFLocked; 聽 聽 聽 聽 聽 聽 聽 聽/* TRUE if file is locked */
聽 聽ADSHANDLE hTable;
聽 聽ADSHANDLE hOrdCurrent;
聽 聽ADSHANDLE hStatement;
} ADSAREA;
typedef ADSAREA * ADSAREAP;
//----------------------------------------------------------------------------//
HB_FUNC( ADSDBFHDL )
{
聽 聽ADSAREAP pArea = hb_rddGetCurrentWorkAreaPointer();
聽 聽if( pArea )
聽 聽 聽 hb_retni( pArea->hTable );
聽 聽else
聽 聽 聽 hb_retni( 0 );
}
//----------------------------------------------------------------------------//
HB_FUNC( ADSISSHARED )
{
聽 聽ADSAREAP pArea = hb_rddGetCurrentWorkAreaPointer();
聽 聽if( pArea )
聽 聽 聽 hb_retl( pArea->fShared );
聽 聽else
聽 聽 聽 hb_retl( HB_FALSE );
}
//----------------------------------------------------------------------------//
HB_FUNC( ADSISREADONLY )
{
聽 聽ADSAREAP pArea = hb_rddGetCurrentWorkAreaPointer();
聽 聽if( pArea )
聽 聽 聽 hb_retl( pArea->fReadonly );
聽 聽else
聽 聽 聽 hb_retl( HB_FALSE );
}
//----------------------------------------------------------------------------//El caso es que necesito de una alma caritativa que intente compilar este c贸digo con BCC a 64b para ver por donde cruje y que soluci贸n se le puede dar.
Si salvo este obst谩culo podr茅 evolucionar junto a FWH, si no quedar茅 atr谩s con los 32b.
Deseo actualizarme. FWH evoluciona sin prisa pero sin pausa. Me gusta.
Muchas gracias,
Un Saludo
Carlos G.
FiveWin 25.12 + Harbour 3.2.0dev (r2502110321), BCC 7.7 Windows 11 Home