Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Building Controls / June 2006

Tip: Looking for answers? Try searching our database.

LoadControlState won't be fired

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Andrea - 05 Jun 2006 23:58 GMT
I'm building a webcontrol, and I want to implement the COntrolState.
Despite I've followed the MSDN sample, and checked with a lot of post
over the net, the LoadControlState(object state) event won't be never
fired.

I don't understand why.

this is the method call I do

protected override void LoadControlState(object state)
        {
            if (state != null)
.....

and the OnInit is like this

    protected override void OnInit(EventArgs e)
        {
            Page.RegisterRequiresControlState(this);
            base.OnInit(e);
        }

I've tried to swith the RegisterRequiresControlState up or down without take
effects.

My code will run over the Save method but never reload data ... What's is
the matter

Every post I've found wasn't unsolved.

Thanks for any suggestion.

Andrea
Brock Allen - 07 Jun 2006 00:51 GMT
LoadControlState will only get called if there's a postback. Is a post back
occuring on your page?

-Brock
http://staff.develop.com/ballen

> I'm building a webcontrol, and I want to implement the COntrolState.
> Despite I've followed the MSDN sample, and checked with a lot of post
[quoted text clipped - 27 lines]
>
> Andrea

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.