Click here to Skip to main content
15,920,438 members
Home / Discussions / Web Development
   

Web Development

 
GeneralRe: DataGrid inconsistent after sorting Pin
Allad26-Jun-07 0:59
Allad26-Jun-07 0:59 
GeneralRe: DataGrid inconsistent after sorting Pin
Vasudevan Deepak Kumar26-Jun-07 2:09
Vasudevan Deepak Kumar26-Jun-07 2:09 
GeneralRe: DataGrid inconsistent after sorting Pin
Allad26-Jun-07 4:30
Allad26-Jun-07 4:30 
QuestionIf...Then... Else based upon QueryString Pin
sduffield25-Jun-07 11:05
sduffield25-Jun-07 11:05 
AnswerRe: If...Then... Else based upon QueryString Pin
Fred_Smith25-Jun-07 11:58
Fred_Smith25-Jun-07 11:58 
GeneralRe: If...Then... Else based upon QueryString Pin
sduffield26-Jun-07 3:13
sduffield26-Jun-07 3:13 
GeneralRe: If...Then... Else based upon QueryString Pin
Fred_Smith26-Jun-07 3:15
Fred_Smith26-Jun-07 3:15 
Questionjavascript form.reset() issue after the postback of an asp.net page Pin
Ken.A25-Jun-07 8:11
Ken.A25-Jun-07 8:11 
hi. i have a simple page with some textboxes, a submit button and a client-side reset button.

1. for this first scenario, i fill the textboxes and the reset button works fine in case i click on it

2. for the second scenario, after i filled the form, i submit it and after the postback, since it's an aspnet page
i have the textboxes filled ... in case i click the reset button the textboxes will not be cleared, but it will be
reset to the previous values, because now the reset will 'think' that the original values are not the empty ones,
but the ones i have filled the form

note: i also set the enableviewstate=false to the textboxes
note: if i do a server.transfer then i have the textboxes cleared, but this is no option, since after the submit i show a message in the page, plus i don't want to postback a page just to clear the form elements
note: i reset the form elements with the following code:

1
2 function ResetForm()
3 {
4 var formId = <%= "'" + Form.ClientID + "'" %>;
5 document.forms[formId].reset();
6 }
7

someone may say to use a javascript code to look for the form elements i want to reset and set its values to empty, but again why? since i have a built-in reset method

so, as far as my understanding goes, form.reset, reset form fields to its original values, not necessarily empty values ... after the postback, the original form values will be the ones i had filled in, like in the second scenario example.

any tips on how to properly reset this form?

»»» KenA
AnswerRe: javascript form.reset() issue after the postback of an asp.net page Pin
badgrs25-Jun-07 9:57
badgrs25-Jun-07 9:57 
GeneralRe: javascript form.reset() issue after the postback of an asp.net page Pin
Ken.A25-Jun-07 10:24
Ken.A25-Jun-07 10:24 
GeneralRe: javascript form.reset() issue after the postback of an asp.net page Pin
Vasudevan Deepak Kumar25-Jun-07 22:06
Vasudevan Deepak Kumar25-Jun-07 22:06 
GeneralRe: javascript form.reset() issue after the postback of an asp.net page Pin
Vasudevan Deepak Kumar25-Jun-07 22:04
Vasudevan Deepak Kumar25-Jun-07 22:04 
GeneralRe: javascript form.reset() issue after the postback of an asp.net page Pin
Ken.A26-Jun-07 5:54
Ken.A26-Jun-07 5:54 
GeneralRe: javascript form.reset() issue after the postback of an asp.net page Pin
Ken.A26-Jun-07 9:56
Ken.A26-Jun-07 9:56 
Questiontransparency on IE Pin
xxrono25-Jun-07 3:54
xxrono25-Jun-07 3:54 
AnswerRe: transparency on IE Pin
Vasudevan Deepak Kumar25-Jun-07 5:28
Vasudevan Deepak Kumar25-Jun-07 5:28 
AnswerRe: transparency on IE Pin
Shog925-Jun-07 6:58
sitebuilderShog925-Jun-07 6:58 
QuestionStylesheet Problem in IE 7 Pin
Sachin Pimpale25-Jun-07 3:35
Sachin Pimpale25-Jun-07 3:35 
AnswerRe: Stylesheet Problem in IE 7 Pin
Vasudevan Deepak Kumar25-Jun-07 5:27
Vasudevan Deepak Kumar25-Jun-07 5:27 
QuestionImage caching, IE7 problem! Pin
ErikZ25-Jun-07 3:05
ErikZ25-Jun-07 3:05 
AnswerRe: Image caching, IE7 problem! Pin
Vasudevan Deepak Kumar25-Jun-07 5:26
Vasudevan Deepak Kumar25-Jun-07 5:26 
GeneralRe: Image caching, IE7 problem! Pin
ErikZ25-Jun-07 22:46
ErikZ25-Jun-07 22:46 
QuestionCode problems [modified] Pin
matjame25-Jun-07 2:37
matjame25-Jun-07 2:37 
AnswerRe: Code problems Pin
PrakashBhaskar25-Jun-07 2:44
PrakashBhaskar25-Jun-07 2:44 
GeneralRe: Code problems Pin
matjame25-Jun-07 2:51
matjame25-Jun-07 2:51 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.