Page 1 of 1

new bug xBrowse 20.02 [solved]

Posted: Sun Apr 19, 2020 9:30 am
by MOISES
Hello,

ISome customers are reporting me this error in xBrowse:

Event description: Problem BASE/1004 There is no method: SORT
Args:
[ 1] = U

Code: Select all


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

METHOD AdoIncrSeek( uSeek ) CLASS TXBrowse

   local lFound   := .f.
   this line-> local cCol     := CharRem( "[]", StrToken( ::oRs:Sort, 1 ) )
 
Thank you

Re: new bug xBrowse 20.02

Posted: Wed Apr 22, 2020 7:13 am
by MOISES
Up

Re: new bug xBrowse 20.02

Posted: Wed Apr 22, 2020 10:16 am
by Silvio.Falconi
perhaps ::oRs:Sort() ?

Re: new bug xBrowse 20.02

Posted: Wed Apr 22, 2020 4:48 pm
by nageswaragunupudi

Code: Select all

Event description: Problem BASE/1004 There is no method: SORT
Args:
[ 1] = U
 
This error indicates that the value of oBrw:oRs is NIL.
Please check your application why oBrw:oRs is becoming nil.

Re: new bug xBrowse 20.02

Posted: Wed Apr 22, 2020 5:27 pm
by MOISES
Thank you for your reply. I hope you're in good health.

Some customers reported this error, but they are working with Access in a local pc, with no lan or Internet involved.

Can you please, as a safety precaution, check that oBrw:oRs is not nil before contunuing with this method?

Re: new bug xBrowse 20.02

Posted: Wed Apr 22, 2020 7:27 pm
by MOISES
Probably the user has an active oBrowse:oSeek, and he deletes the record, so oRs becomes to nil.

How can we handle it?

Thank you.

Re: new bug xBrowse 20.02

Posted: Mon Apr 27, 2020 6:21 am
by nageswaragunupudi
Probably the user has an active oBrowse:oSeek, and he deletes the record, so oRs becomes to nil.
Deleting one record does not close the RecordSet.
Deleting a record using oBrw:Delete() is always safe.

Re: new bug xBrowse 20.02

Posted: Mon Apr 27, 2020 8:09 am
by MOISES
Thank you very much for your attention.

We have not been able to reproduce the generation of the error, in which case we could have provided you with a more precise solution. It could even be an ADO error itself.

So, as an additional security measure, could you please modify the code of xbrowse, something like that:

Code: Select all

METHOD AdoIncrSeek( uSeek ) CLASS TXBrowse

   local lFound   := .f.
   local cCol     := ""
   local cExpr    := ''
   local cType, d, uVal, lSoft, cSaveFilt

   if hb_isnil( ::oRs )
      return .f.
   endif
   
   cCol     := CharRem( "[]", StrToken( ::oRs:Sort, 1 ) )


 

Re: new bug xBrowse 20.02

Posted: Tue Apr 28, 2020 10:12 am
by nageswaragunupudi
done

Re: new bug xBrowse 20.02 [solved]

Posted: Tue Apr 28, 2020 11:14 am
by MOISES
Thank you very much!

Re: new bug xBrowse 20.02 [solved]

Posted: Thu May 07, 2020 2:57 pm
by MOISES
I am afraid you undid the changes in FW 20.04:

Code: Select all

METHOD AdoIncrSeek( uSeek ) CLASS TXBrowse

   local lFound   := .f.
   local cCol     := CharRem( "[]", StrToken( ::oRs:Sort, 1 ) )
   local cExpr    := ''
   local cType, d, uVal, lSoft, cSaveFilt

   if ::oRs == nil
      return .f.
   endif
cCol will fail because it should be after if ::oRs == nil:

Code: Select all

  

   if ::oRs == nil
      return .f.
   endif
   
   cCol     := CharRem( "[]", StrToken( ::oRs:Sort, 1 ) )
Thank you.

Re: new bug xBrowse 20.02 [solved]

Posted: Thu May 07, 2020 3:21 pm
by nageswaragunupudi
You are right
Sorry
Please make the proper modification in your copy.
We will incorporate it for next release.