471,317 Members | 1,588 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

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

conflicting info between debugger and page

I have a strange behaviour as follows:

public class SaveWebControlObject
{
public WebControl control;
}
public partial class Default : System.Web.UI.Page
{
SaveWebControlObject swco = new SaveWebControlObject();
protected void ButtonClick1(...) // click a button
{
Label1.Text = "button clicked";
sco.control = Label1;
}
protected void ButtonClick2(...) // undo a button click
{
((Label)sco.control).Text = "undone";
}
}
I debugged ButtonClick2() method and it confirmed that the label object
saved in SaveWebControlObject.control was assigned the text "undone"
but it fails to show up on the page.
What am I missing here?

Rich

Feb 20 '06 #1
0 918

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Guadala Harry | last post: by
4 posts views Thread by Jack Russell | last post: by

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.