FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour How to use AX_GetActivityInfo() of ADS V.9
Posts: 1598
Joined: Fri Oct 07, 2005 05:56 PM
Re: How to use AX_GetActivityInfo() of ADS V.9
Posted: Mon Jul 16, 2012 07:45 AM
Dear Reinaldo,

I try this but it cannot use AdsCloseSQLStatement( cAlias ) to close the cursor and I cannot Create another ADSCreateSQLStatement() again.
Code (fw): Select all Collapse
Function  ...()
cAlias  := "cursor"
cSql        := "EXECUTE PROCEDURE sp_mgGetInstallInfo()"
ADSCreateSQLStatement( cAlias )
AdsExecuteSQLDirect( cSql )
?(cAlias)->Owner, (cAlias)->SerialNumber, (cAlias)->UserOption

AdsCloseSQLStatement( cAlias )
return nil

Regards,
Dutch
Regards,

Dutch



FWH 2304 / xHarbour Simplex 1.2.3 / BCC73 / Pelles C / UEStudio

FWPPC 10.02 / Harbour for PPC (FTDN)

ADS V.9 / MySql / MariaDB

R&R 12 Infinity / Crystal Report XI R2

(Thailand)
Posts: 990
Joined: Thu Nov 17, 2005 05:49 PM
Re: How to use AX_GetActivityInfo() of ADS V.9
Posted: Mon Jul 16, 2012 01:17 PM
Dutch;

Hi.

Add this wrapper to adsfunc.c and rebuild rdd_ads.lib that you link to your app. I may be making things more complicated for you and it might just be simpler if we change ExecuteAdsSqlScript. If you are able to rebuild the lib, then it just might make sense to add this wrapper. Let me know if it works for you:

Code (fw): Select all Collapse
//---------------------------------------------------------------------------//
//RCB  11/11/2010 1:48:28 PM
//---------------------------------------------------------------------------//

HB_FUNC( ADSCLOSESQLSTATEMENT )
{
    ADSAREAP pArea = hb_adsGetWorkAreaPointer();

    if( pArea && pArea->hStatement )
    {
        UNSIGNED32 ulRetVal = AdsCloseSQLStatement( pArea->hStatement );

        if( ulRetVal == AE_SUCCESS )
        {

            hb_retl( TRUE );
        }
        else
        {
            HB_TRACE(HB_TR_DEBUG, ("AdsCloseSQLStatement() error") );
            hb_retl( FALSE );
        }
    }
    else
        hb_retl( FALSE );
}


Reinaldo.
Posts: 1598
Joined: Fri Oct 07, 2005 05:56 PM
Re: How to use AX_GetActivityInfo() of ADS V.9
Posted: Tue Jul 17, 2012 11:13 AM
Dear Reinaldo

I try AdsCloseSQLStatement() but it Links error as below. This function has in RDDADS.LIB (xHarbour 1.2.1) already, I don't know why it has error message.
Code (fw): Select all Collapse
--------------------Configuration: EZ4AR5 - Release--------------------
xHarbour Compiler build 1.2.1 (SimpLex) (Rev. 6406)
Copyright 1999-2009, http://www.xharbour.org <!-- m --><a class="postlink" href="http://www.harbour-project.org/">http://www.harbour-project.org/</a><!-- m -->
Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
EZ4AR.c:
Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Error: Unresolved external '_HB_FUN_ADSCLOSESQLSTATEMENT' referenced from D:\V5\EZAR\RELEASE\EZ4AR.OBJ
EZ4AR5.EXE - 1 error(s), 0 warning(s)


Thanks,
Dutch
Regards,

Dutch



FWH 2304 / xHarbour Simplex 1.2.3 / BCC73 / Pelles C / UEStudio

FWPPC 10.02 / Harbour for PPC (FTDN)

ADS V.9 / MySql / MariaDB

R&R 12 Infinity / Crystal Report XI R2

(Thailand)
Posts: 990
Joined: Thu Nov 17, 2005 05:49 PM
Re: How to use AX_GetActivityInfo() of ADS V.9
Posted: Tue Jul 17, 2012 02:09 PM

Looks like the function is missing from the rdd_ads.lib? Are you sure you are linking the right .lib? Send me your email and I'll email you an already built rddads.lib for xharbour 1.2.1.

Reinaldo.

Posts: 1598
Joined: Fri Oct 07, 2005 05:56 PM
Re: How to use AX_GetActivityInfo() of ADS V.9
Posted: Tue Jul 17, 2012 03:57 PM

my email : dutchez4 @ gmail.com
Thanks in advance,
Dutch

Regards,

Dutch



FWH 2304 / xHarbour Simplex 1.2.3 / BCC73 / Pelles C / UEStudio

FWPPC 10.02 / Harbour for PPC (FTDN)

ADS V.9 / MySql / MariaDB

R&R 12 Infinity / Crystal Report XI R2

(Thailand)

Continue the discussion