Click here to Skip to main content
15,920,383 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Page Invisible Pin
Venkatesh Mookkan7-Jan-07 15:51
Venkatesh Mookkan7-Jan-07 15:51 
GeneralRe: Page Invisible Pin
indian1437-Jan-07 18:23
indian1437-Jan-07 18:23 
QuestionProblem with button click event handler Pin
Tina P4-Jan-07 18:11
Tina P4-Jan-07 18:11 
AnswerRe: Problem with button click event handler Pin
Christian Graus4-Jan-07 18:30
protectorChristian Graus4-Jan-07 18:30 
GeneralRe: Problem with button click event handler Pin
Tina P5-Jan-07 5:38
Tina P5-Jan-07 5:38 
GeneralRe: Problem with button click event handler Pin
Christian Graus5-Jan-07 19:18
protectorChristian Graus5-Jan-07 19:18 
GeneralRe: Problem with button click event handler Pin
Tina P6-Jan-07 13:46
Tina P6-Jan-07 13:46 
GeneralRe: Problem with button click event handler Pin
Christian Graus6-Jan-07 14:24
protectorChristian Graus6-Jan-07 14:24 
Tina P wrote:
if (!IsPostBack)

This part means your code will never work.  By checking this, your code only works the first time the page is opened, and never on a postback.  Remove it, or otherwise, have your event handler set the local properties, as well as the cookie.  That would make the most sense to me, in a lot of ways.

if (!IsPostback) is used to read settings only the first time a page is opened, and is generally used where an initial state is read, then later changed by the page.  For example, on first load, a data driven control would read it's data from the database, but it's both expensive and causes state to be lost, to read it every time.  Rather than keep reading hte cookie, it makes more sense to store changes in both the cookie, and the local settings, in the event code.  That would also allow you to do this code in the page load ( the pre render problem would have been the issue if the !IsPostback code had not been present )




Christian Graus - C++ MVP

'Why don't we jump on a fad that hasn't already been widely discredited ?' - Dilbert

GeneralRe: Problem with button click event handler Pin
Tina P6-Jan-07 15:27
Tina P6-Jan-07 15:27 
GeneralRe: Problem with button click event handler Pin
Christian Graus6-Jan-07 15:38
protectorChristian Graus6-Jan-07 15:38 
GeneralRe: Problem with button click event handler Pin
Tina P6-Jan-07 16:59
Tina P6-Jan-07 16:59 
GeneralRe: Problem with button click event handler Pin
Christian Graus6-Jan-07 23:23
protectorChristian Graus6-Jan-07 23:23 
GeneralRe: Problem with button click event handler Pin
Tina P7-Jan-07 8:16
Tina P7-Jan-07 8:16 
GeneralRe: Problem with button click event handler Pin
Christian Graus7-Jan-07 9:13
protectorChristian Graus7-Jan-07 9:13 
GeneralRe: Problem with button click event handler Pin
Tina P7-Jan-07 10:32
Tina P7-Jan-07 10:32 
QuestionRe: Problem with button click event handler Pin
Tina P7-Jan-07 11:03
Tina P7-Jan-07 11:03 
Questionproblem dropdownlist Pin
mohd imran abdul aziz4-Jan-07 18:04
mohd imran abdul aziz4-Jan-07 18:04 
AnswerRe: problem dropdownlist Pin
Jay_se4-Jan-07 19:06
Jay_se4-Jan-07 19:06 
AnswerRe: problem dropdownlist Pin
Venkatesh Mookkan4-Jan-07 19:30
Venkatesh Mookkan4-Jan-07 19:30 
QuestionSearch keyword in set of documents stored using Sharepoint Pin
Member 36858894-Jan-07 17:07
Member 36858894-Jan-07 17:07 
QuestionProblem in setting up auto signout when closing the application browser window Pin
Renukapadhamanaban4-Jan-07 14:40
Renukapadhamanaban4-Jan-07 14:40 
AnswerRe: Problem in setting up auto signout when closing the application browser window Pin
Not Active4-Jan-07 15:50
mentorNot Active4-Jan-07 15:50 
GeneralRe: Problem in setting up auto signout when closing the application browser window Pin
Venkatesh Mookkan4-Jan-07 16:43
Venkatesh Mookkan4-Jan-07 16:43 
GeneralRe: Problem in setting up auto signout when closing the application browser window Pin
Not Active4-Jan-07 16:53
mentorNot Active4-Jan-07 16:53 
GeneralRe: Problem in setting up auto signout when closing the application browser window Pin
Venkatesh Mookkan4-Jan-07 16:56
Venkatesh Mookkan4-Jan-07 16:56 

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.