SELECT fileNumber FROM dbo.mortgageLog WHERE fileNumber='#FORM.fileNumber#' #FORM.fileNumber#is taken, please try another")> *taken out for the thread* Each button has its own name: [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => [htmlstate] => on_nl2br [postusername] => dpinder123 [ip] => demetrius@pathw [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 1 [islastshown] => [isfirstshown] => 1 [attachments] => [allattachments] => ) --> one flash form, mulitple submit buttons - Coldfusion Flash Integration

one flash form, mulitple submit buttons - Coldfusion Flash Integration

I'm using the flash form tab navigator in which each tab has a different function. Each tab has it's own submit button. The application is built into one form, with several buttons (currently 3). Anytime I press a button on the the second and third tabs, the app thinks that I'm trying to submit info from the first tab (insertOrder). Flash Forms will be the end of me today. <!---button logic---> <CFIF IsDefined ("FORM.insertOrder")> <cfquery datasource="user" name="orderNumbercheck"> SELECT fileNumber FROM dbo.mortgageLog WHERE fileNumber='#FORM.fileNumber#' </cfquery> <cfif orderNumbercheck.RecordCount GT "0"> <cfset msg2 = URLEncodedFormat("The Order Number <cfoutput>#FORM.fileNumber#</cfoutput>is taken, please try another")> <cflocation ...

  1. #1

    Default one flash form, mulitple submit buttons

    I'm using the flash form tab navigator in which each tab has a different
    function. Each tab has it's own submit button. The application is built into
    one form, with several buttons (currently 3). Anytime I press a button on the
    the second and third tabs, the app thinks that I'm trying to submit info from
    the first tab (insertOrder).

    Flash Forms will be the end of me today.

    <!---button logic--->

    <CFIF IsDefined ("FORM.insertOrder")>
    <cfquery datasource="user" name="orderNumbercheck">
    SELECT fileNumber FROM dbo.mortgageLog WHERE fileNumber='#FORM.fileNumber#'
    </cfquery>
    <cfif orderNumbercheck.RecordCount GT "0">
    <cfset msg2 = URLEncodedFormat("The Order Number
    <cfoutput>#FORM.fileNumber#</cfoutput>is taken, please try another")>
    <cflocation url="mortgageLog.cfm?msg2=#msg2#">
    <cfelse>
    <cfquery datasource="datasource" name="insertOrder">
    *taken out for the thread*
    </cfquery>
    </cfif>
    <CFELSEIF IsDefined ("FORM.updateOrder")>
    <cfdump var="#form#">
    <CFELSEIF IsDefined ("FORM.searchOrder")>
    </CFIF>

    <!---buttons--->
    Each button has its own name:

    <cfinput type="submit" name="insertOrder" value="Submit" id="insertOrder">

    <cfinput type="submit" name="updateOrder" value="Update" id="updateOrder">

    <cfinput type="submit" name="searchOrder" value="search" id="searchOrder">

    dpinder123 Guest

  2. #2

    Default Re: one flash form, mulitple submit buttons

    When ever a submit button is pressed in a flash form, flash submits all the
    data from all the tabs. What you may need to do is to have an on change of the
    tab, call a savecontent and disable all form fields that are not on the current
    tab. I usually make it a habbit to do this all the time so I am not submitting
    more info than I need to.

    Chikowski Guest

  3. #3

    Default Re: one flash form, mulitple submit buttons

    So, I guess you mean something like the code posted below? Am I correct? Do I
    put this after the first tab or on the second tab? I tried on both, it didnt
    work for me.

    <cfformgroup type="page" label="Current Orders" width="900"
    onChange="tabChanging">
    <cfsavecontent variable="tabChanging">
    if selectedIndex=0
    form.fileNumber.enabled="false";
    form.dateOrdered.enabled="false";
    form.fileName.enabled="false";
    form.address.enabled="false";
    form.city.enabled="false";
    form.state.enabled="false";
    form.zip.enabled="false";
    form.lender.enabled="false";
    form.examiner.enabled="false";
    form.notes.enabled="false";
    form.dateRecorded.enabled="false";
    </cfsavecontent>

    dpinder123 Guest

  4. #4

    Default Re: one flash form, mulitple submit buttons

    What you really want is when you click on the frist tab, all the fields on the
    first tab are enabled, the fields second tab and third tab are disabled. When
    you click on the second tab, all the fields on the first and third tab are
    disabled, all the fields on the second tab are enabled. So on and so forth.
    Now to enable and disable the fields you need to use this syntax.

    put the cfsavecontent either at the top of the page or include it on another
    page.

    <cfsavecontent variable="tabChanging">
    if (selectedindex==0)
    {
    doent.fileNumber.enabled = false;
    doent.dateOrdered.enabled = false;
    doent.fileName.enabled = false;
    doent.address.enabled = false;
    doent.city.enabled = false;
    doent.state.enabled = false;
    doent.zip.enabled = false;
    doent.lender.enabled = false;
    doent.examiner.enabled = false;
    doent.notes.enabled = false;
    doent.dateRecorded.enabled = false;
    }
    if (selectedindex==1)
    {
    doent.fileNumber.enabled = true;
    doent.dateOrdered.enabled = true;
    doent.fileName.enabled = true;
    doent.address.enabled = true;
    doent.city.enabled = true;
    doent.state.enabled = true;
    doent.zip.enabled = true;
    doent.lender.enabled = true;
    doent.examiner.enabled = true;
    doent.notes.enabled = true;
    doent.dateRecorded.enabled = true;
    }
    </cfsavecontent>

    <cfform name="myForm" format="flash">
    <cfformgroup type="tabnavigator" onChange="#tabChanging#">

    <cfformgroup type="page" label="Current Orders" width="900">
    </cfformgroup>

    <cfformgroup type="page" label="Past Orders" width="900">
    </cfformgroup>

    </cfformgroup>
    </cfform>

    Chikowski Guest

  5. #5

    Default Re: one flash form, mulitple submit buttons

    Thanks for clearing that up for me.

    I'm now getting this error when the page loads....

    There is no property with the name 'selectedindex'.

    dpinder123 Guest

  6. #6

    Default Re: one flash form, mulitple submit buttons

    Sorry, Forgot. You cannot use the word "SelectedIndex" as a form variable. You would have to pass the value of the selected index to a different variable.
    Chikowski Guest

  7. #7

    Default Re: one flash form, mulitple submit buttons

    Ok, so what you're saying is this:

    selectedIndex is used to number the tabs I have, correct? So, tab # 1 would be
    selectedindex="1" and so on.....

    I need to declare a variable that passes in the "if" logic:
    if (variable==0)

    Where "==" is specific to each tab?

    so, when the user goes from form to form, the input fields on the other tabs
    are disabled; correct?

    so, i have to give each tab a selectedIndex number (which number should I
    start at? I dont know if it works like arrays...)
    and I have to declare a variable.

    Right?

    dpinder123 Guest

  8. #8

    Default Re: one flash form, mulitple submit buttons

    I'm sorry, I am totally confuseing you. Can I send a file to you by way of email?
    Chikowski Guest

  9. #9

    Default Re: one flash form, mulitple submit buttons

    Yes, my email address is dpinder (at) titlefocus.com


    dpinder123 Guest

  10. #10

    Default Re: one flash form, mulitple submit buttons

    I have a similar problem, but my solution has always been to just use "button"
    instead of "submit" type and use remoting to interact with the server to
    update/add/delete data.

    the problem is that whenever I have a "required=yes" field, the standard error
    doesn't always trigger when the field is left blank. I can't find a way to
    trigger it in the actionscript. Any ideas?

    somethingclever Guest

  11. #11

    Default Re: one flash form, mulitple submit buttons

    email me at the above address.
    dpinder123 Guest

  12. #12

    Default Re: one flash form, mulitple submit buttons

    Hi guys,

    I am trying to do exactly the same thing with my very long form. I've been
    playing with
    accordion tabs, button, and flash remoting. however, I haven't been able to
    get it working right. Would please share your approaches via disabling tabs
    approach and button/remoting approach? You maybe my solution to my problems
    I've been frustrated with. I am interested in seeing how to disable the other
    tabs OR how to make the button/remoting approach work with the required fields
    as well.

    thanks you so much you guys!!!

    sakang Guest

  13. #13

    Default Re: one flash form, mulitple submit buttons

    Originally posted by: Chikowski
    If you haven't already, I would take a look at asfusion.com. They have some
    great stuff there. If you do not find what your looking for there, please give
    me your e-mail address so I can send you a file with it all layed out and
    explained for you.

    Hi Chikowski,

    I downloaded the real estate app a month ago and it was a great help, but now
    I've gone into multiple grids and multiple buttons which aren't covered in
    their example. Can you please send me the e-mail that you sent to dpinder123? I
    noticed that when I bind my cfinputs to my 2nd grid, the buttons no longer work
    on my 1st tab. Thanks! I appreciate your help. You're a saint! I hope I can
    learn enough to actually be of help to someone in the near future.

    Thanks again,

    Jennifer

    JennyStarr76 Guest

  14. #14

    Default Re: one flash form, mulitple submit buttons

    Mine is [email]jmostertdevineuniverse.com[/email]. Thanks!
    JennyStarr76 Guest

Similar Threads

  1. cf flash form submit on enter key down?
    By chris in forum Coldfusion Flash Integration
    Replies: 1
    Last Post: November 15th, 04:30 PM
  2. Help with flash form submit
    By duanem103 in forum Coldfusion - Getting Started
    Replies: 3
    Last Post: March 11th, 05:14 PM
  3. Flash Form submit
    By sentill_kumar in forum Macromedia ColdFusion
    Replies: 0
    Last Post: March 7th, 10:27 AM
  4. Flash Form in CF7 Does not submit
    By Mike Nimer in forum Coldfusion - Getting Started
    Replies: 2
    Last Post: February 16th, 06:23 PM
  5. #25366 [NEW]: form buttons of type "image" dont send "submit" $_POST variable in IE
    By jordanolsommer at imap dot cc in forum PHP Development
    Replies: 0
    Last Post: September 2nd, 07:54 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •