Hi,
 
First of all there is one "=" sign missing after the 'action' parameter.
 
At the time of execution of If... Else code, the value of Request.Form("chkButton") 
will always be "", therefore Else will always execute.... resulting in page going to 
page3.asp.
 
To make this work... you'll have to use a client-side script to detect the value of 
chkButton and submit to appropriate page. On click of Submit, call a JavaScript 
method... that will check the value of window.document.formname.chkbutton, and sets 
the value of window.document.formname.action accordingly. Be sure that you are using 
the return keywords appropriately.
 
Regards
Kamran
--

ILyas <[EMAIL PROTECTED]> wrote:
Hi

Is that possible to decide the page when the form is being submitted.
I mean,

Page1.asp:

<form method="post" action"<% if reques.form("chkbutton")="ON" then
response.write "page2.asp" else response.write "page3.asp" %>">
      
      <input type="checkbox" name="chkbutton" value="ON">

</form>

When I tried this, the page is being submitted to page3.asp, always.

ILyas




---------------------------------------------------------------------    
Home       : http://groups.yahoo.com/group/active-server-pages
---------------------------------------------------------------------
Post       : [EMAIL PROTECTED]
Subscribe  : [EMAIL PROTECTED]
Unsubscribe: [EMAIL PROTECTED]
--------------------------------------------------------------------- 


Yahoo! Groups SponsorADVERTISEMENT


---------------------------------
Yahoo! Groups Links

   To visit your group on the web, go to:
http://groups.yahoo.com/group/active-server-pages/
  
   To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
  
   Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. 


                
---------------------------------
Do you Yahoo!?
vote.yahoo.com - Register online to vote today!

[Non-text portions of this message have been removed]






------------------------ Yahoo! Groups Sponsor --------------------~--> 
$9.95 domain names from Yahoo!. Register anything.
http://us.click.yahoo.com/J8kdrA/y20IAA/yQLSAA/17folB/TM
--------------------------------------------------------------------~-> 

---------------------------------------------------------------------    
 Home       : http://groups.yahoo.com/group/active-server-pages
---------------------------------------------------------------------
 Post       : [EMAIL PROTECTED]
 Subscribe  : [EMAIL PROTECTED]
 Unsubscribe: [EMAIL PROTECTED]
--------------------------------------------------------------------- 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/active-server-pages/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to