[V4RB] GoToRecID(xx)
Joakim Schramm
joakim at astrocalc.com
Mon Jul 10 18:54:05 CDT 2006
I don't understand what you people are stumbling on, the property is already
there, VTable.RecID, why type 7 chars more to get the same thing???
Not sure about this with raising an exeption though, but if you need to be
sure there is the RecordExists function. Currently if you "assign" a RecID
that doesn't exist the current recods doesn't change, however if you assign
0 it changes to 0 - I can't really tell if this is good or bad, but I see no
need for a bloat function that aleady exists. Well that's my opinion anyhow.
If you want to set a current record: tbl.RecID = n
If you want to know the current record n = tbl.RecID
If you want to know if it exists: if tbl.RecordExists(n) then ...
Why making it complicated, or is it that it's too easy so the mind makes it
complicated?
Regards,
Joakim
> -----Original Message-----
> From: valentina-bounces at lists.macserve.net
> [mailto:valentina-bounces at lists.macserve.net] On Behalf Of
> Charles Yeomans
> Sent: 10 July 2006 18:35
> To: Valentina Developers
> Subject: Re: [V4RB] GoToRecID(xx)
>
>
> On Jul 7, 2006, at 7:23 PM, Ruslan Zasukhin wrote:
>
> > On 7/8/06 1:30 AM, "Charles Yeomans" <yeomans at desuetude.com> wrote:
> >
> >>> Yes, in fact METHOD
> >>>
> >>> tbl.Goto( inRecID ) as Boolean
> >>>
> >>> Do more job than property. It also can check if such
> record exists
> >>> and return bool result...
> >>
> >>
> >> Please don't force that interface style on us.
> >
> > Sorry, Charles, I have not catch your point of view ?
> >
> > You against to add such method ? Why ?
>
> Why do it that way? We could have a property
> VTable.CurrentRecID as Integer. If you try to assign a bad
> value to CurrentRecID, then the function could either return
> or raise an exception; since it is easy to check CurrentRecID
> as needed, I favor the former, reserving an exception for
> other problems.
>
> Charles Yeomans
> _______________________________________________
> Valentina mailing list
> Valentina at lists.macserve.net
> http://lists.macserve.net/mailman/listinfo/valentina
>
More information about the Valentina
mailing list