FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Autoget Error in FW May 2014 and June 2014
Posts: 842
Joined: Mon Oct 10, 2005 01:29 PM
Autoget Error in FW May 2014 and June 2014
Posted: Fri Jul 11, 2014 09:55 AM

When I try testage5.prg I have this error

Error description: Error BASE/1004 No exported method: EVAL
Args:
[ 1] = U

Stack Calls

Called from: => (b)EVAL( 0 )
Called from: .\source\classes\AUTOGET.PRG => (b)TGETLIST( 312 )
Called from: .\source\classes\AUTOGET.PRG => TGETLIST:KEYCOUNT( 0 )
Called from: .\source\classes\AUTOGET.PRG => TAUTOGET:CREATELIST( 159 )
Called from: .\source\classes\AUTOGET.PRG => TAUTOGET:OPENLIST( 271 )
Called from: .\source\classes\AUTOGET.PRG => (b)TAUTOGET( 54 )
Called from: .\source\classes\AUTOGET.PRG => TAUTOGET:KEYCHAR( 0 )
Called from: => TWINDOW:HANDLEEVENT( 0 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1733 )
Called from: .\source\classes\TGET.PRG => TAUTOGET:HANDLEEVENT( 589 )
Called from: .\source\classes\WINDOW.PRG => _FWH( 3279 )
Called from: => DIALOGBOXINDIRECT( 0 )
Called from: .\source\classes\DIALOG.PRG => TDIALOG:ACTIVATE( 277 )
Called from: TESTAGE5.prg => MAIN( 42 )

Regards Maurizio

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Autoget Error in FW May 2014 and June 2014
Posted: Mon Jul 14, 2014 04:49 PM

Maurizio,

Please try this change in Class TAutoGet:

METHOD KeyCount() INLINE If( ! Empty( ::bKeyCount ), Eval( ::bKeyCount ), 0 )

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 842
Joined: Mon Oct 10, 2005 01:29 PM
Re: Autoget Error in FW May 2014 and June 2014
Posted: Tue Jul 15, 2014 06:58 AM

Antonio,
now no error , but doesn't work , when I press a letter nothing happens .

Thank Maurizio

www.nipeservice.com

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Autoget Error in FW May 2014 and June 2014
Posted: Tue Jul 15, 2014 07:07 AM

Maurizio,

Class TAutoGet has been developed by Daniel García Gil, I am going to ask him, thanks

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 PM
Re: Autoget Error in FW May 2014 and June 2014
Posted: Tue Jul 15, 2014 11:16 AM

Hello

the integration with DBF is not implemented yet, the sample testage5.prg didn't should be distributed until finish the DBF integration, please use an array or hash instead of DBF

sorry my mistake

Posts: 82
Joined: Fri Mar 03, 2006 06:26 PM
Re: Autoget Error in FW May 2014 and June 2014
Posted: Sun May 14, 2017 11:56 AM

Hello Daniel,

Was testage5.prg ever completed? Has anybody got an example of a wild seek using DBFCDX?

Regards
David

Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: Autoget Error in FW May 2014 and June 2014
Posted: Thu May 18, 2017 11:36 AM
Till integration with DBF is completed by Mr Daniel, we can use this sample to use DBF
Code (fw): Select all Collapse
#include "fivewin.ch"
#include "autoget.ch"

REQUEST DBFCDX

static lSeekWild := .t.

function main()

   field FIRST

   local oDlg, oGet, cName, cName1, cName2
   local oRs,  cAlias := "CUST"
   cName := space(20)

   USE CUSTOMER NEW ALIAS CUST SHARED VIA 'DBFCDX'
   INDEX ON UPPER(FIRST) TAG FIRST1 TO TMP MEMORY
   SET ORDER TO TAG FIRST1
   GO TOP

   define dialog oDlg title "Test Autoget" size 600, 480 pixel

   @ 1,2 autoget oGet var cName of oDlg ;
         DATASOURCE {};
         FILTER CUST->( ListFilter1( uDataSource, cData, Self ) );
         COLUMN 1 ;
         HEIGHTLIST 100

   @ 3,2 BUTTON "ok" OF odlg ACTION msgalert("Get 1:"+cName)
   @ 3,20 BUTTON "close" OF odlg ACTION odlg:end()

   activate dialog oDlg centered

return nil

//---------------------------------------------------------------------------//
// match case without case sensitive
function ListFilter1( aList, cData, oSelf )

   local aNewList := {}
   local cFor     := Upper( AllTrim( cData ) )
   local bFor

   if lSeekWild
      cFor     := '"' + cFor + '" $ UPPER(FIRST)'
   else
      cFor     := 'UPPER(FIRST)="' + cFor + '"'
   endif

   bFor     := &( "{ ||" + cFor + "}" )

   aNewList    := FW_DbfToArray( "FIRST", bFor )

RETURN aNewList

//---------------------------------------------------------------------------//

You may toggle static variable lSeekWild as .T. or .F.
Regards



G. N. Rao.

Hyderabad, India

Continue the discussion