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 / May 2006

Tip: Looking for answers? Try searching our database.

LoadControlState Event Not Firing?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
seraphimrhapsody@gmail.com - 23 May 2006 16:08 GMT
Hello all,

I've created a custom control that inherits CompositeControl for the
purpose of extending the gridview and using dynamically created
dropdowns to filter that gridview.

My main problem is persisting the dropdowns' values across postbacks,
so I thought that control state would be perfect for this issue (since
it's required for the control to function properly).

After reading countless tutorials and blogs and newsgroups posts about
the subject, I'm finally at my wits end. I seem to have setup
everything correctly, and my SaveControlState() event fires as
expected, but the LoadControlState() event never fires at all.

I've posted my fully commented code here: http://pastebin.com/733065

Am I missing something? Did I not require it correctly? Is that
statement in the incorrect place?

Thank in advance for anyone's help!
--SeraphimRhapsody
seraphimrhapsody@gmail.com - 23 May 2006 16:34 GMT
Also, the implementation of using this control would look something
like this:

cc1:FilteredGV ID="FilteredGV1" runat="server" SelectCommand="select *
from companies where (([ID] like @ID) AND ([CompanyName] like
@CompanyName) AND ([SubmitName] like @SubmitName))"
               ConnectionString="Data Source=dev;Initial
Catalog=myDB;Persist Security Info=True;User ID=sa;Password=*****" >
               <Parameters>
                   <asp:ListItem value="ID"></asp:ListItem>
                   <asp:ListItem value="CompanyName"></asp:ListItem>
                   <asp:ListItem value="SubmitName"></asp:ListItem>
               </Parameters>
           </cc1:FilteredGV>

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.