My hunch is that there is no object defined on this page that is called
"NewOpt". The "NewOpt" object would be something like a form field name,
select list object name, or ???. Is this borrowed code where the object has
been renamed to something else for your purposes?
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of Dan Slater
> Sent: Friday, February 16, 2001 4:54 PM
> To: '[EMAIL PROTECTED]'
> Subject: RE: ThreeSelectsRelated.cfm
>
>
> David,
>
> It seems you've gotten further along than I have - but...
> (there's always a
> but)
>
> I still (after implementing your replacement section) have the same errors
> when trying to use this custom tag on an "edit" page.
>
> When I want the 3 selects related to show what the user actually selected
> when adding the record it works fine. But when attempting to
> change the 2nd
> select to point at a new option - I get the following:
>
> A Runtime Error has occurred.
> Do you wish to Debug?
>
> Line: 5903
> Error: 'NewOpt' is undefined
>
> And when viewing the code in debug I see:
>
> tot = NewOpt.length;
> lst = document.EditEntry.WorkOrders.options.length;
>
> for (i = lst; i > 0; i--) {
> document.EditEntry.WorkOrders.options[i] = null;
> }
> for (i = 0; i < tot; i++) {
> document.EditEntry.WorkOrders.options[i] = NewOpt[i];
> }
>
> document.EditEntry.WorkOrders.options[0].selected = true;
>
> }
>
> Anyone got any ideas as to what's going on here? I was so relieved to see
> that someone solved the bug in 3selectsrelated - only to find out
> it wasn't
> MY bug.... :(
>
> Dan Slater
> JOATMON
> www.buxtonco.com
>
>
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Friday, February 16, 2001 3:37 PM
> To: [EMAIL PROTECTED]
> Subject: Re: ThreeSelectsRelated.cfm
>
>
>
>
> Mark,
>
> The bug is in the third drop down code.
>
> Try replacing the section with this. (Plz note we added a new attribute
> Tab# to
> set the TabIndex which is not in the original)
>
> <CFOUTPUT><SELECT NAME="#Attributes.Name3#" SIZE="#Attributes.Size3#"
> TabIndex="#Attributes.Tab3#" <CFIF Attributes.Multiple3 is "Yes">MULTIPLE
> </CFIF><CFIF Attributes.Width3 is not
> "">STYLE="width:#Attributes.Width3#"</CFIF><CFIF
> Attributes.OnChange is not
> "">
> OnChange="#Attributes.OnChange#"</CFIF>></CFOUTPUT>
> <CFSET SecondGroup = Attributes.Default2>
> <CFSET CurrentGroup3 = "">
> <CFIF Attributes.EmptyText3 is "">
> <CFLOOP QUERY="MyQuery">
> <CFIF Evaluate("MyQuery.#Attributes.Value2#") is
> Variables.SecondGroup>
> <CFSET ThisValue =
> Evaluate("MyQuery.#Attributes.Value3#")>
> <CFIF Variables.ThisValue is not Variables.CurrentGroup3>
> <CFOUTPUT><OPTION VALUE="#Variables.ThisValue#" <CFIF
> Variables.ThisValue is
> Attributes.Default3>SELECTED</CFIF>>#Evaluate("MyQuery.#Attributes
> .Display3#
> ")#</CFOUTPUT>
>
> <CFSET CurrentGroup3 =
> Evaluate("MyQuery.#Attributes.Value3#")>
> </CFIF>
> <!--- <CFELSE>
> <CFBREAK> --->
> </CFIF>
> </CFLOOP>
> </CFIF>
>
> <CFIF Attributes.ForceWidth3 is not ""><CFOUTPUT><OPTION
> VALUE="">#RepeatString(Attributes.ForceWidthChar,
> Attributes.ForceWidth3)#</CFOUTPUT></CFIF>
> <CFIF Attributes.ExtraOptions3 is not ""><CFLOOP
> INDEX="This" FROM="1"
> TO="#Attributes.ExtraOptions3#"><CFOUTPUT><OPTION
> VALUE=""></CFOUTPUT></CFLOOP></CFIF>
> <CFOUTPUT></SELECT></CFOUTPUT>
>
>
>
>
>
>
> "Mark Kent" <[EMAIL PROTECTED]> on 02/16/2001 12:18:16 AM
>
> Please respond to [EMAIL PROTECTED]
>
> To: [EMAIL PROTECTED]
> cc: (bcc: David L Moser/TX/ONE)
> Subject: ThreeSelectsRelated.cfm
>
>
>
> Has anyone ever got this to work to their satisfaction? I've got a decent
> query that looks very similar to the example that comes with the code, but
> it's not working right. I found a coding error in the tag file itself:
> <CFPARAM NAME="Attributes.ForceWidth4" DEFAULT="">
> and changed it to:
> <CFPARAM NAME="Attributes.ForceWidth3" DEFAULT="">
>
> I'm going to email the author, Nate Weiss, but I wanted to know if anyone
> else has successfully used this tag. I'd like to add the "EMPTYTEXT"
> parameter, but that really makes it act screwy.
>
> Thanks.
> mark
>
>
>
> -------------------------------------------------------------------------
> This email server is running an evaluation copy of the MailShield anti-
> spam software. Please contact your email administrator if you have any
> questions about this message. MailShield product info: www.mailshield.com
>
> -----------------------------------------------
> To post, send email to [EMAIL PROTECTED]
> To subscribe / unsubscribe: http://www.dfwcfug.org
>
>
>
>
>
>
>
> -------------------------------------------------------------------------
> This email server is running an evaluation copy of the MailShield anti-
> spam software. Please contact your email administrator if you have any
> questions about this message. MailShield product info: www.mailshield.com
>
> -----------------------------------------------
> To post, send email to [EMAIL PROTECTED]
> To subscribe / unsubscribe: http://www.dfwcfug.org
>
> -------------------------------------------------------------------------
> This email server is running an evaluation copy of the MailShield anti-
> spam software. Please contact your email administrator if you have any
> questions about this message. MailShield product info: www.mailshield.com
>
> -----------------------------------------------
> To post, send email to [EMAIL PROTECTED]
> To subscribe / unsubscribe: http://www.dfwcfug.org
-------------------------------------------------------------------------
This email server is running an evaluation copy of the MailShield anti-
spam software. Please contact your email administrator if you have any
questions about this message. MailShield product info: www.mailshield.com
-----------------------------------------------
To post, send email to [EMAIL PROTECTED]
To subscribe / unsubscribe: http://www.dfwcfug.org