Second Pair Of Eyes

2004-08-31 Thread Adrian Lynch
Can anyone see something wrong with this, working on CFMX but failing on CF5 function formValue(formName, defaultValue) { if ( IsDefined("FORM.#ARGUMENTS.formName#") ) { return HTMLEditFormat(FORM["#ARGUMENTS.formName#"]); } else { return HTMLEditFormat(ARGUMENTS.defaultValue); } } Er

Re: Second Pair Of Eyes

2004-08-31 Thread Bert Dawson
in CF5 arguments is an array: try: IsDefined("FORM.#ARGUMENTS[1]#") I think that will work on MX too. HTH Bert - Original Message - From: Adrian Lynch <[EMAIL PROTECTED]> Date: Tue, 31 Aug 2004 16:22:29 +0100 Subject: Second Pair Of Eyes To: CF-Talk <[EMAIL PROTECTE

Re: Second Pair Of Eyes

2004-08-31 Thread Ray Champagne
You don't need the #'s inthe isDefined - just the FORM.whatever variable. I don't have a means to test this right now, but this jumped out at me. Rau At 11:22 AM 8/31/2004, you wrote: >Can anyone see something wrong with this, working on CFMX but failing on CF5 > > >function formValue(formName,

Re: Second Pair Of Eyes

2004-08-31 Thread Qasim Rasheed
Have you tried usinge structkeyexits() instead of isDefined() - Original Message - From: Adrian Lynch <[EMAIL PROTECTED]> Date: Tue, 31 Aug 2004 16:22:29 +0100 Subject: Second Pair Of Eyes To: CF-Talk <[EMAIL PROTECTED]> Can anyone see something wrong with this, working

RE: Second Pair Of Eyes

2004-08-31 Thread d.a.collie
This works on CF5 function formValue(formName, defaultValue) {   if (structKeyExists(FORM, formName) ) {    return HTMLEditFormat(FORM[formName]);   } else {    return HTMLEditFormat(defaultValue);   } } Arguments is an array rather than a structure -- dc

RE: Second Pair Of Eyes

2004-08-31 Thread Adrian Lynch
ubject: Re: Second Pair Of Eyes You don't need the #'s inthe isDefined - just the FORM.whatever variable. I don't have a means to test this right now, but this jumped out at me. Rau At 11:22 AM 8/31/2004, you wrote: >Can anyone see something wrong with this, working on CFMX but

Re: Second Pair Of Eyes

2004-08-31 Thread S . Isaac Dealey
He does if the the form element he's looking for is named by an argument in his function, i.e. getFormElement("myform") - if this function does anything with the value of "form.myform", then he does need the #'s. Although I tend to use structkeyexists() for this. In which case there wouldn't be #'

RE: Second Pair Of Eyes

2004-08-31 Thread Gavin Brook
It also works fine on MX. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 31 August 2004 16:46 To: CF-Talk Subject: RE: Second Pair Of Eyes This works on CF5 function formValue(formName, defaultValue) {   if (structKeyExists(FORM, formName

RE: Second Pair Of Eyes

2004-08-31 Thread Pascal Peters
In cf5, arguments is an array. Just use formName and defaultValue without a prefix (or arguments[1] and arguments[2]). Pascal > -Original Message- > From: Adrian Lynch [mailto:[EMAIL PROTECTED] > Sent: 31 August 2004 17:22 > To: CF-Talk > Subject: [Spam?] Second Pair O

RE: Second Pair Of Eyes

2004-08-31 Thread Dave Watts
> Arguments is an array rather than a structure If I recall correctly, the Arguments "object" is exposed as both an array and a structure. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ phone: 202-797-5496 fax: 202-797-5444 [Todays Threads] [This Message] [Subscription] [Fast U

RE: Second Pair Of Eyes

2004-08-31 Thread Pascal Peters
Not in CF5. That is where the problem was. Pascal > -Original Message- > From: Dave Watts [mailto:[EMAIL PROTECTED] > Sent: 31 August 2004 18:40 > To: CF-Talk > Subject: [Spam?] RE: Second Pair Of Eyes > > > Arguments is an array rather than a structure > &

RE: Second Pair Of Eyes

2004-08-31 Thread S . Isaac Dealey
>> Arguments is an array rather than a structure > If I recall correctly, the Arguments "object" is exposed > as both an array > and a structure. > Dave Watts, CTO, Fig Leaf Software > http://www.figleaf.com/ > phone: 202-797-5496 > fax: 202-797-5444 On MX you're right, although the original que

RE: Second Pair Of Eyes

2004-09-01 Thread d.a.collie
dc said... > >> Arguments is an array rather than a structure dave watts said... > > If I recall correctly, the Arguments "object" is exposed > > as both an array > > and a structure. s. isaac dealey said... >  On MX you're right, although the original question was on CF5. OK... run th