Ask a Question related to Dreamweaver AppDev, Design and Development.

  1. #1

    Default Submit and Cancel

    Hi guys,

    And another very simple one. I actually stumbled for the 1st time on a
    situation where I'd like to have 2 buttons on a form, one to indicate
    "Yes, do it" (Submit) and one to indicate "No, forget it" (Cancel),
    anlogous to a windows MsgBox dialog. The "Yes, do it" is a simple submit
    button. But how do I do the "Cancel" function ? How do I know that the
    user has clicked Cancel and not Submit, when the form has been submitted ?

    I don't want to have to resort to radio buttons... Ah, BTW, can I have,
    like for radio buttons, a "submit button group" with the same name, and
    I can ask for the value (text) of the button with
    Request.Form("button-name") ??

    Thanks for help
    Bernard
    bthouin Guest

  2. Similar Questions and Discussions

    1. how to cancel a webservice?
      HI, In my client application (a CSharp Windows App), I invoke a webservice function. Because these client applications are sometimes running...
    2. Cancel a Form
      How can I close a form avoiding the data join in record source table?
    3. Cancel As Integer
      If an event procedure include the argument Cancel As Integer, you can cancel the event with: Cancel = True For example, if you want to stop the...
    4. Cancel submit?
      Is there a way to cancel the submit process from the client using vbscript?
    5. Cancel this post
      Never mind, I just realized that I can process the input in the form rather than the textbox. God Bless, Mark A. Sam
  3. #2

    Default Re: Submit and Cancel

    >>can I have, like for radio buttons, a "submit button group" with the
    same name, and I can ask for the value (text) of the button with
    Request.Form("button-name")<<
    Well. I just tried, and it works exactly that way. So I solved my
    problem. Sorry to have bothered you...

    Bernard

    bthouin wrote:
    > Hi guys,
    >
    > And another very simple one. I actually stumbled for the 1st time on a
    > situation where I'd like to have 2 buttons on a form, one to indicate
    > "Yes, do it" (Submit) and one to indicate "No, forget it" (Cancel),
    > anlogous to a windows MsgBox dialog. The "Yes, do it" is a simple submit
    > button. But how do I do the "Cancel" function ? How do I know that the
    > user has clicked Cancel and not Submit, when the form has been submitted ?
    >
    > I don't want to have to resort to radio buttons... Ah, BTW, can I have,
    > like for radio buttons, a "submit button group" with the same name, and
    > I can ask for the value (text) of the button with
    > Request.Form("button-name") ??
    >
    > Thanks for help
    > Bernard
    bthouin Guest

  4. #3

    Default Re: Submit and Cancel

    Here is a vbScript I use to verify deleting a record, you can modify it for
    submitting a record.

    <SCRIPT LANGUAGE="VBScript">
    <!-- This function allows the user to confirm deleting this record before
    deleting it SK 1/17/05 -->
    Function form1_onSubmit
    If Msgbox("Are you sure you want to delete this sub-title?", vbYesNo +
    vbExclamation) = vbNo Then
    form1_onSubmit = False
    End If
    End Function
    </SCRIPT>

    But if you are just using a simple button next to your submit button that says
    cancel, then why don't you just change the button from a submit button to none
    and place the behavior "onclick" go to URL... or something like this.

    stacekz Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139