Page 1 of 1
Problem in AdoIncrSeek( ) of xHarbour
Posted: Tue Aug 05, 2014 12:36 pm
by Maurizio
Hello
I have a xBrowse with a ADO table , if I press the key ' ( example I seek TEST' )
The problem is in ::oRs:Find( cExpr, 0, 1, 1 )
where cExpr --> DESCRI LIKE 'TEST'*'
Regards Maurizio
Re: Problem in AdoIncrSeek( ) of xHarbour
Posted: Tue Aug 05, 2014 12:51 pm
by nageswaragunupudi
Please locate these lines:
Please insert one line above if ::lSeekWild
Code: Select all | Expand
do case
case cType == 'C'
uSeek := StrTran( uSeek, "'", "''" ) // inserted
if ::lSeekWild
Note: Replace single "single quote" with "two single quotes".
Let us see if this works.
Normally we avoid quotes. etc in seeks and filters.
Re: Problem in AdoIncrSeek( ) of xHarbour
Posted: Tue Aug 05, 2014 1:54 pm
by Maurizio
Thanks ,
it works perfectly
Maurizio
Re: Problem in AdoIncrSeek( ) of xHarbour
Posted: Tue Aug 05, 2014 2:16 pm
by nageswaragunupudi
Maurizio wrote:Thanks ,
it works perfectly
Maurizio
Thanks for your testing.
We shall include that.
But again we can not seek double quotes

Re: Problem in AdoIncrSeek( ) of xHarbour
Posted: Tue Aug 05, 2014 4:36 pm
by Maurizio
Hello Rao
another question .
I have a xBrowse with a ADO Table , I need to make a new SELECT in the same browse .
Is it possible without closing and reopening the browse ?
Ghirardini Maurizio
www.nipeservice.com
Re: Problem in AdoIncrSeek( ) of xHarbour
Posted: Tue Aug 05, 2014 5:11 pm
by nageswaragunupudi
Yes, thats what we intended to provide. At the same time let me confess that I did not do much testing. You can help to test and see how it works.
First assuming that the columns (fields) are identical, replace oBrw:oRs with new recordset.
oNewRs := <open a new recordset with revised SELECT statement>
oSaveRs :- oBrw:oRs
oBrw:oRs := oNewRs
oBrw:GoTop()
oBrw:Refresh()
oSaveRs:Close()
oSaveRs := nil
Please see if this works without any problems.
Re: Problem in AdoIncrSeek( ) of xHarbour
Posted: Wed Aug 06, 2014 6:44 am
by Maurizio
Thanks Rao
your example works .
This works to
oBrw:oRs := oRsNew
oBrw:GoTop()
oBrw:Refresh()
Regards MAurizio
www.nipeservice.com
Re: Problem in AdoIncrSeek( ) of xHarbour
Posted: Thu Mar 22, 2018 3:05 am
by nageswaragunupudi
This may be better
Code: Select all | Expand
WITH OBJECT oBrw
:lScreenUpdating := .f.
:oRs:Close()
:oRs:Source := <revised SQL statement>
:oRs:Open()
:GoTop()
:lScreenUpdating := .t.
:Refresh()
END
Re: Problem in AdoIncrSeek( ) of xHarbour
Posted: Thu Mar 22, 2018 4:11 pm
by Maurizio
Thanks Rao
Maurizio
www.nipeservice.com