That seems like what I would need. Looking at the code, I have a few
questions. Please excuse my ignorance.
-----------------------------
<cfparam name="attributes.required" type="boolean">
<cfparam name="attributes.column" type="string">
<cfparam name="attributes.label" type="string">
<cfparam name="attributes.optionDisplayTextList" type="string">
<cfparam name="attributes.optionValueList" type="string">
<cfif ListLen(attributes.optionDisplayTextList) neq
ListLen(attributes.optionValueList)>
<div class="important">GenericPopulatedDropdown custom tag requires that
the optionValueList and the optionDisplayTextList be the same size.</div>
<cfabort>
</cfif>
<cf_DisplaySelectMenu column="#attributes.column#"
label="#attributes.label#" required="#attributes.required#">
<cfloop list="#attributes.optionValueList#" index="optionValue">
<cfset displayText =
ListGetAt(attributes.optionDisplayTextList,ListFind(attributes.optionValueLi
st,optionValue))>
<cf_DisplayOption displaytext="#displayText#"
value="#optionValue#">
</cfloop>
</cf_DisplaySelectMenu>
-----------------------------
Question 1--attributes.column, is that the column where the value will be
stored? Do I need to prepend the table name ("Jobs.Estimator" or simply
"estimator")?
Question 2--how do I pass the query.column to
attributes.optionDisplayTextList and the second query.column to
attributes.optionValueList? I am guessing I have to make the query into
lists somehow?
Question 3-- can the attributes.optionValueList be type = integer?
Question 4--Attributes would simply be passed in as such?...
<cf_GenericPopulatedDropdown required = "yes" column = "estimator" label =
"Job Estimator" optionDisplaytextList = "plumUser.UserName" optionValueList
= "PlumUser.UserId"></cf_genericPopulatedDropdown>?
Thanks a lot John, I think this will work if I can just get my brain to grow
enough to use it.
Mark Fuqua
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of John
Stanley
Sent: Tuesday, August 02, 2005 3:32 PM
To: '[email protected]'
Subject: RE: [plum] context validation error for tag cfselect
I never use cfselect, if i needed to, I would just use select but that wont
help with your current problem, interestingly enough I created a custom tag
that creates plum dropdowns that uses the plum cf_DisplaySelectMenu custom
tag if you are interested. It can create the dropdown from a query object or
a list (or other stuff like arrays too).
the tag assumes that you send in two lists which can be
#valuelist(plumusers.userID)# and #valuelist(plumusers.username)#.
the other attributes are pretty self explanatory, and it insinuates itself
nicely in the plum forms, at least in my experience.
let me know if you use it and what problems/questions/concerns you have.
-----Original Message-----
From: Mark Fuqua [mailto:[EMAIL PROTECTED]
Sent: Tuesday, August 02, 2005 3:23 PM
To: [email protected]
Subject: [plum] context validation error for tag cfselect
Hey there,
I'm trying to use a <cfselect> tag within <cf_displayExtraFormContent> tag.
I am getting the following error:
"context validation error for tag cfselect"
The first time I got the error I assumed it was because it was within the
<cf_displayExtraFormContent> tag. But when I moved the <cfselect> outside
the <cf_DisplayAddForm> tag, I still get the same error.
Here is the select:
<cfselect name="estimators" required="yes" message="pick one"
query="plumusers" value="userId" display="username"></cfselect>
A <cfdump> reveals the query is returning the expected results.
Thanks for the help,
Mark Fuqua
**********************************************************************
You can subscribe to and unsubscribe from lists, and you can change
your subscriptions between normal and digest modes here:
http://www.productivityenhancement.com/support/DiscussionListsForm.cfm
**********************************************************************
**********************************************************************
You can subscribe to and unsubscribe from lists, and you can change
your subscriptions between normal and digest modes here:
http://www.productivityenhancement.com/support/DiscussionListsForm.cfm
**********************************************************************