Error after update for FWH 7.11

Post Reply
User avatar
vilian
Posts: 795
Joined: Wed Nov 09, 2005 2:17 am
Location: Brazil
Contact:

Error after update for FWH 7.11

Post by vilian »

Hi,

Error: Unresolved external 'AdsCloseCachedTables' referenced from C:\XHARBOUR\LIB\RDDADS.LIB|adsfunc


Sds,
Vilian F. Arraes
Sds,
Vilian F. Arraes
vilian@vfatec.com.br
Belém-Pa-Brazil
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Vilian,

From http://www.xharbour.org/index.asp?page=news/20050324:

# Added AdsCacheOpenTables() and AdsCacheOpenCursors() function. (for all versions Ads) and AdsCloseCachedTables() for Ads 7.x and above. ADS_REQUIRE_VERSION 7 must be set for the last function

# Allow setting of ADS_REQUIRE_VERSION using compiler command line switch
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
vilian
Posts: 795
Joined: Wed Nov 09, 2005 2:17 am
Location: Brazil
Contact:

Post by vilian »

Antonio,

I did not understand. Not use AdsCloseCachedTables() in my system.
Sds,
Vilian F. Arraes
vilian@vfatec.com.br
Belém-Pa-Brazil
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Vilian,

As a workaround try to add this code to your main PRG:

Code: Select all

#pragma BEGINDUMP

void AdsCloseCachedTables( void ) {}

#pragma ENDDUMP
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
vilian
Posts: 795
Joined: Wed Nov 09, 2005 2:17 am
Location: Brazil
Contact:

Post by vilian »

Antonio,

Unhappyly it did not decide the problem.
Sds,
Vilian F. Arraes
vilian@vfatec.com.br
Belém-Pa-Brazil
User avatar
James Bott
Posts: 4654
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA
Contact:

Post by James Bott »

Vilian,

If you are not using ADS, then there are two libs you should not be linking into you app. RDDADS.LIB and ACE32.LIB.

James
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Vilian,

> Unhappyly it did not decide the problem.

Do you get the same error ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
vilian
Posts: 795
Joined: Wed Nov 09, 2005 2:17 am
Location: Brazil
Contact:

Post by vilian »

Antonio,

The error message is the same one:

Code: Select all

Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Error: Unresolved external 'AdsCloseCachedTables' referenced from C:\XHB\LIB\RDDADS.LIB|adsfunc
One will detail interesting that I observed is that in the installation of xHarbour that comes with FWH 7.11 does not have the Ace32.lib archive.
Sds,
Vilian F. Arraes
vilian@vfatec.com.br
Belém-Pa-Brazil
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Vilian,

> does not have the Ace32.lib archive

Thats because you have to create that library yourself from the used ACE32.dll:

implib.exe Ace32.lib Ace32.dll
regards, saludos

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

Post by Antonio Linares »

Vilian,

Try it this way:

Code: Select all

#pragma BEGINDUMP 

#include <windows.h>

void pascal AdsCloseCachedTables( void ) 
{
   MessageBox( 0, "inside AdsCloseCachedTables", "ok", 0 );
} 

#pragma ENDDUMP
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
vilian
Posts: 795
Joined: Wed Nov 09, 2005 2:17 am
Location: Brazil
Contact:

Post by vilian »

Antonio,

Now it´s fine. Thank you
Sds,
Vilian F. Arraes
vilian@vfatec.com.br
Belém-Pa-Brazil
hua
Posts: 861
Joined: Fri Oct 28, 2005 2:27 am

Post by hua »

Antonio Linares wrote:
Try it this way:

Code: Select all

#pragma BEGINDUMP 

#include <windows.h>

void pascal AdsCloseCachedTables( void ) 
{
   MessageBox( 0, "inside AdsCloseCachedTables", "ok", 0 );
} 

#pragma ENDDUMP
When I got this error, initially I just try to create a stub function

Code: Select all

function AdsCLoseCachedTables()
return nil
But that didn't solve the problem. Only after putting in Antonio's code above does it links with no error. Out of curiousity, why is it so?

Ok, back to play with 7.12 :)
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

> Out of curiousity, why is it so?

Because the linker is requiring a C level function, not a PRG level one :-)
regards, saludos

Antonio Linares
www.fivetechsoft.com
Post Reply