Click here to Skip to main content
15,905,679 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionDatagrid paging........ Pin
Nagraj Naik25-Aug-06 0:19
Nagraj Naik25-Aug-06 0:19 
AnswerRe: Datagrid paging........ [modified] Pin
Suresh Pirsquare25-Aug-06 0:33
Suresh Pirsquare25-Aug-06 0:33 
GeneralRe: Datagrid paging........ Pin
Nagraj Naik25-Aug-06 0:42
Nagraj Naik25-Aug-06 0:42 
QuestionE-Commerce Site Pin
tmoney10125-Aug-06 0:12
tmoney10125-Aug-06 0:12 
AnswerRe: E-Commerce Site Pin
minhpc_bk25-Aug-06 13:28
minhpc_bk25-Aug-06 13:28 
QuestionE-Commerce Site Pin
tmoney10125-Aug-06 0:12
tmoney10125-Aug-06 0:12 
QuestionEventHandler not added when TreeView is created programmatically within if (!IsPostBack) Pin
tengstedt24-Aug-06 23:38
tengstedt24-Aug-06 23:38 
AnswerRe: EventHandler not added when TreeView is created programmatically within if (!IsPostBack) Pin
Mircea Grelus24-Aug-06 23:54
Mircea Grelus24-Aug-06 23:54 
The thing is that the postback resets the page to it's original state, so any information regarding the dynamically created controls is lost. Why is that? Because the Page class is stateless. The Page recreates child controls based on the tags in the aspx files, so your controls not being present there are not shown. That's why you need to recreate them. Their values are persisted in ViewSate however, so you only need to create the tags again (with the same ID of course) and you do not have to assign values again (that is if you want the values of the controls as they were on postback.

There is no other way around it. It's how ASP.NET works.

regards,
Mircea
Many people spend their life going to sleep when they’re not sleepy and waking up while they still are.

GeneralRe: EventHandler not added when TreeView is created programmatically within if (!IsPostBack) Pin
tengstedt25-Aug-06 0:28
tengstedt25-Aug-06 0:28 
QuestionData type of functions Pin
Kartik Rathi24-Aug-06 23:17
Kartik Rathi24-Aug-06 23:17 
AnswerRe: Data type of functions Pin
Paddy Boyd24-Aug-06 23:24
Paddy Boyd24-Aug-06 23:24 
GeneralRe: Data type of functions Pin
_AK_24-Aug-06 23:29
_AK_24-Aug-06 23:29 
AnswerRe: Data type of functions Pin
Mircea Grelus24-Aug-06 23:27
Mircea Grelus24-Aug-06 23:27 
GeneralRe: Data type of functions Pin
_AK_24-Aug-06 23:29
_AK_24-Aug-06 23:29 
QuestionWhy Different browsers showing different size of asp.net controls? Pin
thomas_joyee24-Aug-06 23:14
thomas_joyee24-Aug-06 23:14 
AnswerRe: Why Different browsers showing different size of asp.net controls? Pin
Mircea Grelus24-Aug-06 23:36
Mircea Grelus24-Aug-06 23:36 
GeneralRe: Why Different browsers showing different size of asp.net controls? Pin
thomas_joyee24-Aug-06 23:50
thomas_joyee24-Aug-06 23:50 
GeneralRe: Why Different browsers showing different size of asp.net controls? Pin
_AK_25-Aug-06 0:00
_AK_25-Aug-06 0:00 
QuestionHow to support different different date formats in web application Pin
Software_Guy_12324-Aug-06 23:04
Software_Guy_12324-Aug-06 23:04 
AnswerRe: How to support different different date formats in web application Pin
_AK_24-Aug-06 23:10
_AK_24-Aug-06 23:10 
GeneralRe: How to support different different date formats in web application Pin
Software_Guy_12325-Aug-06 0:42
Software_Guy_12325-Aug-06 0:42 
GeneralRe: How to support different different date formats in web application Pin
_AK_25-Aug-06 0:48
_AK_25-Aug-06 0:48 
GeneralRe: How to support different different date formats in web application Pin
Software_Guy_12325-Aug-06 1:10
Software_Guy_12325-Aug-06 1:10 
GeneralRe: How to support different different date formats in web application Pin
_AK_25-Aug-06 1:18
_AK_25-Aug-06 1:18 
QuestionCAPTCHA image in ASP Pin
Arghya_mp24-Aug-06 22:59
Arghya_mp24-Aug-06 22:59 

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.