473,387 Members | 1,573 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Submit Button

I have a web form with a few text fields some validataion and a submit
button.

When I click the submit bittin the serverside event does not fire?????
Why!!!! I have tried Changing the EnableViewState I have tried removing
CausesValidataion.
I am using VisualStudio 2003/.net 1.1

<asp:Button id="submit" runat="server" Text="Update" EnableViewState="True"
CausesValidation="true"></asp:Button>
private void InitializeComponent()
{
this.submit.Click += new System.EventHandler(this.submit_Click);
this.Load += new System.EventHandler(this.Page_Load);
}
#endregion
private void submit_Click(object sender, System.EventArgs e)
{
Response.Write("This is the button clicked");
// Update the users file here
userRec.Replace(txtName.Text,14,0,0);
userRec.Replace(txtEmail.Text,13,0,0);
userRec.Replace(txtFax.Text,21,0,0);
userRec.Replace(txtVoice.Text,19,0,0);
tblEUsers.Write(userId,userRec);
if (txtPass.Text != "") // save the password
{
}
}

Kevin Bilbee
Nov 17 '05 #1
1 2125
the property Page.IsValid is what fires the validation event. you must
check in you page somewhere.

"Kevin Bilbee" <kb*****@standardabrasives.com> wrote in message
news:O$**************@TK2MSFTNGP12.phx.gbl...
I have a web form with a few text fields some validataion and a submit
button.

When I click the submit bittin the serverside event does not fire?????
Why!!!! I have tried Changing the EnableViewState I have tried removing
CausesValidataion.
I am using VisualStudio 2003/.net 1.1

<asp:Button id="submit" runat="server" Text="Update" EnableViewState="True" CausesValidation="true"></asp:Button>
private void InitializeComponent()
{
this.submit.Click += new System.EventHandler(this.submit_Click);
this.Load += new System.EventHandler(this.Page_Load);
}
#endregion
private void submit_Click(object sender, System.EventArgs e)
{
Response.Write("This is the button clicked");
// Update the users file here
userRec.Replace(txtName.Text,14,0,0);
userRec.Replace(txtEmail.Text,13,0,0);
userRec.Replace(txtFax.Text,21,0,0);
userRec.Replace(txtVoice.Text,19,0,0);
tblEUsers.Write(userId,userRec);
if (txtPass.Text != "") // save the password
{
}
}

Kevin Bilbee

Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Matt | last post by:
I want to understand the difference between submit button and regular button: <input type="submit"> and <input type="button">. My understanding is that submit button will send the entire HTML form...
2
by: jb | last post by:
Hello, I need to know which button was pressed in the submit , i tried reading the vaule of submit it the validateDate function but it returns 'undefined' value ; I do this in asp all the time, Not...
15
by: Mattia | last post by:
Hi! I have a <form> that can be submitted thruogh three buttons and I need to tell witch one was pressed when the form was submitted. I now do it with 3 <input type="submit" name="..."...
15
by: M Smith | last post by:
I have a form I want to submit to itself. I want to be able to type in a list of numbers and submit the form and have that list show up on the same form under the text box I typed them into and...
3
by: Adam | last post by:
Hey guys, I've decided to stop banging my head against the wall and just ask you guys for the answer. I can't seem to find it. I have a form in which I have multiple submit buttons; only, I'm...
8
by: bettina | last post by:
I want to submit a form but without a submit button. That's to say, I want that by giving a definite code in a field and then press <ENTER> the form will be submitted. For Example <form...
5
by: rjames.clarke | last post by:
I have the following. $result=mysql_query($sql); $nrows=mysql_num_rows($result); for ($i=0;$i<$nrows;$i++) { $row_array=mysql_fetch_row($result); echo "<form name='testform'...
10
by: ljlolel | last post by:
So.. I have a form that submits to an ASP.net site made in C-sharp. The ASP site is not mine, i do not have the server side code. When I submit from my form by pressing the Submit button, I get...
10
by: The Natural Philosopher | last post by:
I am coding up a bit of javascript stuff, and have managed to stumble my way through most of what I want.. But this one has got me stumped. I call submit() and get a javascript error 'Submit...
4
by: j1dopeman | last post by:
Hi, I'd like to use a button to save and then submit a form. I can set the onlick of the button to mahButton_click or submit, but I can't figure out how to do both. It looks like c# can't...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.