Across the board yesterday , I read "avoid evaluate", but I could not
find any guidelines on when it "must" be used.

I usually see it being used in situations where the variable is being
named dynamically, such as the case of passing a list of form fields
(form.MyRadio1, form.MyRadio2, etc.).  I have read the solution to
this being one of addressing the scope as a structure, like so:

form["MyRadio" & IndexNo]

I have not tested this yet, as it seems this is an MX feature and I am
on CF 5 for the next week or so.

However, I am dealing with a situation shared by Bec Gorton where I am
reading the column names from the database.  Here is an example of the
logic:

I have a Table column called: MyDynamicVariable

The value of MyDynamicVariable = MyVariable

If I output MyDynamicVariable, I get "MyVariable".

However, I want to output MyVariable, which = "John".

The only way I know to do this is evaluate MyDynamicVariable.  

A similar logic could be found by passing a variable name in a form field.

So is there a way around using evaluate in this situation?

Chad
who says, "Nice smile, Bec!"
http://www.aad.gov.au/MediaLibrary/asset/mediaitems/ml_382894364467593_Bec_1.jpg

---
You are currently subscribed to cfaussie as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
Aussie Macromedia Developers: http://lists.daemon.com.au/

Reply via email to