Go Premium for a chance to win a PS4. Enter to Win


Coldfusion (CFC's, Autosuggest, binding and Ajax)

Posted on 2009-05-10
Medium Priority
Last Modified: 2012-05-06

I am fairly new to using CFC's and Ajax in Coldfusion and really enjoying the potential.

I found an autosuggest tutorial that works great for me.  It is here:


I have a list of customers that I choose from our database using this method.  I start typing their name and I get a suggested list to choose from.  Upon choosing the name, it populates the form field with the value I setup in the CFC.  As expected.  

How can I have more than one field in the form I am working on auto populate?  Let's say that I choose the customer from the "auto suggest" field and when I click on them....it not only fills in that field, but 4 more fields(cfinput type="text") under it (account number, email address, shipping address, etc,..etc..)?

Thank You for any insight or info you can provide!

Question by:tomhwtt
1 Comment

Accepted Solution

Jonah11 earned 1500 total points
ID: 24359185
Hey Tom,

I'm not sure if the CFC autosuggest has built-in support for something like this, but one thing you could always do is simply create an onChange javascript function, and it would be called when the autosuggestion was selected and populated.  That function could then do an AJAX query to your database and select the other client information based on the name key, and then use the info to populate the other fields.

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

PROBLEM: How to add your own buttons to the bottom toolbar with paging info ( result count ). While creating a cfgrid, I ran into an issue where I wanted to embed my own custom buttons where the default ones ( insert / delete / etc… ) are for aes…
The most up-to-date version of this article is on my Blog https://iconoun.com/blog/
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…

876 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question