🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: Ver 7.01 => Rowset.fields["***"].value - problem

#1217
From: Ken Chan
Date: Wed, 08 Apr 1998 00:00
26 lines
1577 bytes
Karsten Tinzmann wrote:
> Do you have an idea why I always get an Invalid Subscript Reference Error
> for the following code?
> 
> function CUSTOMERGROUPNAMECOMBOBOX_onChange
>        this.rowset = form.cstgrpdl1.rowset
>        form.SelectedGroup = this.rowset.fields["CustomerGroup"].value
>        this.form.MainNotebook.EntryField4.value = form.SelectedGroup
>        return

Although Romain correctly points out that THIS is the combobox in this 
context, the code you have creates a rowset property of the combobox in 
the first line, so the second line should execute without error (although 
it is not "good" coding practice) as long as you really do have a field 
named "CustomerGroup" in form.cstgrpl1.rowset.

You could try the debugger, or insert the following line:

  inspect( this.rowset.fields )

as the second line and see what fields are in the fields array.

-- 
//Ken@Borland
<Please follow-up to newsgroup; do not reply to email>
Technical Details
Message-ID: <MPG.f95a52197688a039898e2@forums.borland.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <6garpt$kna2@forums.borland.com> <MPG.f942400466c19e698ab7f@forums.borland.com> <6gdjtj$nha8@forums.borland.com> <MPG.f9476687b33bdc498ab8b@forums.borland.com> <6gebug$odk2@forums.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: ff5a1,f0d0f8bab29d096a
X-Google-Attributes: gidff5a1,public
From: supportinfo@borland.com (Ken Chan)
Subject: Re: Ver 7.01 => Rowset.fields["***"].value - problem
Date: 1998/04/08
Message-ID: <MPG.f95a52197688a039898e2@forums.borland.com>
X-Deja-AN: 342252911
References: <6garpt$kna2@forums.borland.com> <MPG.f942400466c19e698ab7f@forums.borland.com> <6gdjtj$nha8@forums.borland.com> <MPG.f9476687b33bdc498ab8b@forums.borland.com> <6gebug$odk2@forums.borland.com>
Organization: Borland
Newsgroups: borland.public.vdbase.data.sql