Actually, this is what I ended up having to do. I still don't understand
why BD can't handle this, but what are gonna do right?

<cfloop query="iquery">

<cfif ivalue eq evaluate(valcol)><cfset selected =
"selected"><cfelse><cfset selected = ""></cfif>

<cfset iout[x] = "<option value=""#evaluate(valcol)#""
#selected#>#htmleditformat(evaluate(labelcol))#</option>">

<cfset x = x+1>

</cfloop>

Anyway, that seems to be working pretty well now. When I have some more
time I'm going to put some real energy into figuring out why BD was
choking on that code.

Thanks,

Ken Ferguson

Fitz and Floyd

http://www.fitzandfloyd.com <http://www.fitzandfloyd.com>

http://www.exclusivelyfitz.com <http://www.exclusivelyfitz.com/>

http://stores.ebay.com/fitzandfloydscharmingtails

  _____  

From: S. Isaac Dealey [mailto:[EMAIL PROTECTED]
Sent: Tuesday, July 13, 2004 12:08 PM
To: CF-Talk
Subject: Re: CF to BD inconsistencies

> I've just started moving some stuff over to a server
> running BlueDragon
> (free version) and I've found a couple of
> inconsistencies...

> Anyone know why the following code works fine in CFMX but
> not so well in
> BlueDragon. When run in BlueDragon I get an error:
> "Invalid index to
> query column. valcol cannot be evaluated to an integer
> value."

Hey Ken,

Ahh yes, the input functions, I remember them well... still using
similar stuff in my own code these days, although it's evolved quite a
bit in the last year.

not sure about the error, but it looks as though BD is expecting the
row number first and the column name second -- which is the reverse of
the way CF handles queries... i.e. iquery[x][valcol] instead of
iquery[valcol][x]. That's just a guess -- though if that's the case,
then it _really_ needs to be fixed in BD.

If you want to follow Liotta's advice and break it out into separate
rows, it'd look like this:

<cfset selected = "">
<cfset thisoption = iquery[valcol][x]>
<cfif listfind(ivalue,thisoption)>
  <cfset selected = "selected">
</cfif>

Don't forget to var "thisoption" and that will definately tell you
what specifically is causing the error.

I believe there's a BD mailing list on the new-atlanta site also.

p.s. you probably ought to drop the maxlength argument off the end of
that function -- not sure how that got in there, should have just been
for the text input function. :)

s. isaac dealey   954.927.5117

new epoch : isn't it time for a change?

add features without fixtures with
the onTap open source framework
http://www.sys-con.com/story/?storyid=44477&DE=1

  _____
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to