Help insert this HTML code into CFFORM

I am trying to learn how to use action script and CF FORMS, this is the first time I have been trying to use it.  Basically I am trying to load mp3 files dynamically.  Here is my code:

<cfquery name="x" datasource="jem_music">

<cfform format="Flash">
  <cfgrid name="UsersGrid" format="Flash" query="x" maxRows="5" rowheaders="Yes">
    <cfgridcolumn name="song" header="Song Title">
    <cfgridcolumn name="band" header="Group Name">
    <cfgridcolumn name="category" header="Category">
  <cfformitem type="text" name="song" label="Song Name" bind="Song Title: {UsersGrid.dataProvider[UsersGrid.selectedIndex]['song']}">}"></cfformitem>
  <cfformitem type="text" name="band" label="Band" bind="Group Name: {UsersGrid.dataProvider[UsersGrid.selectedIndex]['band']}"></cfformitem>
  <cfformgroup type="horizontal">
  <cfformitem type="html" height="100" width="100" bind=""></cfformitem>

Basically all I want to do is load the "Wimpy Button" (which is a flash mp3 player) with a mp3 file dynamically from my database.  Here is the code they use

      <!-- Start Wimpy Button Code -->
<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
 codebase=",0,47,0" name="wimpy_button01"
 WIDTH="40" HEIGHT="40" id="wimpy_button_1">
      <PARAM NAME=movie VALUE="wimpy_button.swf?theFile=example.mp3">
      <PARAM NAME=quality VALUE=high>
      <PARAM NAME=wmode VALUE=transparent>
      <EMBED src="wimpy_button.swf?theFile=example.mp3" WIDTH="40" HEIGHT="40" quality=high NAME="wimpy_button01"
 TYPE="application/x-shockwave-flash" PLUGINSPAGE=""></EMBED>
<!-- End Wimpy Button Code -->

I have a column in my mySQL database called mp3 which has the file name like testfile.mp3, so I want to bind this flash code with the grid so that if i choose i different song with the grid it will change this line below to reflect what the new mp3 file name is:

<PARAM NAME=movie VALUE="wimpy_button.swf?theFile=example.mp3">

So to sum it all up, how can I include the mp3 button into my grid code so that I can play an MP3 file dynamically.

Thank you,
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Although it is possible to dynamically assign a value within the row of the grid and have it link (you can see how this is done here):

If you change the link url to be a popup you could easily use this.

The other possibility would be to have two versions of the form (one that shows if an ID is passed) and one that shows if it wasn't.  Then outside the flash form just use an iframe or simply make your form only take up part of the page - and place the HTML part at the bottom.

Due to the limitations of the <cfformitem type="html"> I am not aware of any way to use embeded objects within the flash form itself.  In order to do this you would need to code the connector in Actionscript and use the <cfformitem type="script"> and code an AS function that could then be called at the bottom of the form.  Sorry I can't provide a complete example of this or test it but hopefully someone much better at actionscript can assist.  You can always check the following two sites for expanded 'hacks' of the CFFORM and AS integration:  AND - they're both great resources for this kind of thing.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
This article from asfusion seems to suggest that you could include your mp3 player swf directly into a hidden text area (without the embedded object tags).

You would pass the name of the file and a start or stop command using actionscript in a similar fashion to the way they do with this file upload swf, but the methods that they call in this article are a function of the file upload swf and how that part is done I'm afraid I am totally in the dark.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Servers

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.