Ray,

I've done that sort of thing, but not using CFFormGroup, or CFSelect. I typically use normal HTML form and select tags using ColdFusion to build the HTML for me if I need to... perhaps something like:

<select Name="MySelect">
    <CFLoop query="getAllProviders">
       <CFSet ThisProvider = Trim(getAllProviders.Provider) & " " & Trim(getAllProviders.ProviderLocation)>
       <option value="999999999">#ThisProvider#</option>
    </CFLoop>
</select>

Whether or not the option is pre-selected can be handled as well.

Would something like this work for you?

Chris

Ray Hughes wrote:
Hi All

I have a piece of code that works which I built. Now I want to extend it
such that the value field is a concatenated value of two fields from the database.

Working part:
<cfformgroup type="page" label="Provider">
    <cfselect name="Provider" label="Provider:" query="getAllProviders"
        queryPosition="below" display="Provider" value="ProviderLocation">
        <option value="9999999999" selected>Any Provider</option>
    </cfselect>
</cfformgroup>

This is the same:
<cfformgroup type="page" label="Provider">
    <cfselect name="Provider" label="Provider:" query="getAllProviders"
        queryPosition="below"


This display function I want to extend.
I want to display the concatenated value of two fields from the database.
display="Provider & ProviderLocation"


This is the same:
value="ProviderLocation">
        <option value="9999999999" selected>Any Provider</option>
    </cfselect>
</cfformgroup>

Has anyone attempted to do this before?

This is the error I receive. I have tried several different combination.

Query column invalid or missing.
You must specify the name of a column in the query "getAllProviders" for the Display attribute of the CFSelect tag.

Regards

_________________________________________________________________
FREE pop-up blocking with the new MSN Toolbar – get it now! http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/


_______________________________________________
Reply to DFWCFUG:  [email protected]
Subscribe/Unsubscribe:  http://lists1.safesecureweb.com/mailman/listinfo/list
List Archives:    http://www.mail-archive.com/list%40list.dfwcfug.org/              http://www.mail-archive.com/list%40dfwcfug.org/
DFWCFUG Sponsors:  www.HostMySite.com  www.teksystems.com/


_______________________________________________
Reply to DFWCFUG: 
  [email protected]
Subscribe/Unsubscribe: 
  http://lists1.safesecureweb.com/mailman/listinfo/list
List Archives: 
    http://www.mail-archive.com/list%40list.dfwcfug.org/             
  http://www.mail-archive.com/list%40dfwcfug.org/
DFWCFUG Sponsors: 
  www.HostMySite.com 
  www.teksystems.com/

Reply via email to