Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > Viewstate lose data

Thread Tools

Viewstate lose data

Posts: n/a
Hi every one
This is the problem:

I have a UserControl that contains a Repeater and a few LinkButton.
The Repeater generate some linkButton.
I use this control for implementing paging solution for another repeater in

(So I have a repeater and a Usercontrol that contains repeater)

When click the stand-alone LinkButton inside the control,
it postback and execute page_load and then it's click event handler.
When click the the Repeater's Generated LinkButton, it postback and only
execute the page_load.
It can not find and don't execute the Repeater's ItemCommand Event handler.

I've defind the repeater's itemcommand event handler and linked the
eventhandler in repeater's html tage like this:

<asp:repeater id="Repeater1" OnItemCommand="Repeater1_ItemCommand"
OnItemDataBound="Repeater1_ItemDataBound" runat="server">

Another scenario is like this below:
When I sort the main repeater, the repeater inside the control, lose it's
data. I mean there is no
linkbutton inside the repeater.
It looks lose its data inside the viewstate.
Because, when I put this control in another page (empty), everything is fine.

Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Ajax-ly updated controls lose their viewstate gnewsgroup ASP .Net 2 10-31-2007 02:35 PM
You lose some, and then you lose some ... Lawrence D'Oliveiro NZ Computing 13 09-24-2006 08:29 AM
About possible data lose warning Vinodh Kumar P C++ 9 12-09-2004 07:39 PM
DG lose viewstate Amir ASP .Net Datagrid Control 0 10-15-2004 05:13 AM
Whay do I lose viewstate in my usercontrol Gerald Klein ASP .Net 0 01-24-2004 04:32 AM