🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.vdbase.data.sql
Article #909

Rowset navigation and field values problem

#909
From: Andrew Knight
Date: Mon, 29 Jun 1998 00:00
43 lines
1680 bytes
I am trying to use the rowset onNavigate event to populate unlinked
entryfields on my form. I am using the following code:

function rowset_OnNavigate()
if .NOT. (form.members1.rowset.endOfset)
    class::refreshUnlinked()
endif

Whenever I try to navigate (using a grid control) I get the message:

   Error: Variable undefined: FORM

I do, however, call the above OnNavigate function from the OnOpen event of
the query object and that does not cause an error message. I have tried
explicitly referencing the form object and passing the form object as a
parameter to the OnNavigate function but to no avail.

Can anyone help me out here?

If I use the 'this' keyword instead of 'form.members1.rowset' it seems to
work as it does call the refreshUnlinked function but therein lies another
problem.

My refreshUnlinked function attempts to assign values to unlinked
entryfields on my form by performing arithmetic on fields in the rowset,
i.e:

form.ef_balance.value = form.members1.rowset.fields["DUE"].value - ;

form.members1.rowset.fields["PAID"].value

This gives me:

    Error: Data type mismatch. Expecting: Object

Huh!

Help. I am confused.

Andrew Knight
Gaborone
Botswana
Technical Details
Message-ID: <6n8ous$1gf15@forums.borland.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: ff5a1,ae3b594a89ea4a34,start
X-Google-Attributes: gidff5a1,public
From: "Andrew Knight" <aknight@global.bw>
Subject: Rowset navigation and field values problem
Date: 1998/06/29
Message-ID: <6n8ous$1gf15@forums.borland.com>
X-Deja-AN: 367183827
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.2106.4
Organization: Base 2 Consultants (Pty) Ltd
Newsgroups: borland.public.vdbase.data.sql