 |
| ASP.NET 1.0 and 1.1 Professional For advanced ASP.NET 1.x coders. Beginning-level questions will be redirected to other forums. NOT for "classic" ASP 3 or the newer ASP.NET 2.0 and 3.5 |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the ASP.NET 1.0 and 1.1 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|

November 1st, 2006, 06:30 AM
|
|
Friend of Wrox
|
|
Join Date: Aug 2004
Posts: 550
Thanks: 0
Thanked 1 Time in 1 Post
|
|
Urgent Issue to be sorted out
Hi friends/parsons
I have a usercontrol for pagination, in that control I pass the datagrid reference. There is an event handler within that usercontrol that is used to bind the grid. The user control has the following options:
First, Prev, Next, Last, a dropdown showing pages out of total pages and a label showing total no of records out of total records.
Everything works fine till I place a single usercontrol for the grid on that page, but if I place 2 usercontrols of paging (on top and bottom) to the same grid on the same page, only that control is affected on which I click, i.e. if I click on the usercontrol placed on top of the grid, total records, dropdown index changes for that control only, not for the control that I placed below the grid.
Any help would be appreciated.
Regards
Mike
Fortune favours the brave, so don't regret on missed oppurtunities.
__________________
Regards
Mike
|
|

November 1st, 2006, 08:35 AM
|
|
Wrox Author
|
|
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
|
|
Well, unless you link the 2 user controls together somehow (like control 1 raises an event in control 2) how does control 2 even know how/when to change?
-------------------------
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
^^Thats my signature
|
|

November 1st, 2006, 09:35 AM
|
|
Friend of Wrox
|
|
Join Date: Aug 2004
Posts: 550
Thanks: 0
Thanked 1 Time in 1 Post
|
|
Yup
I can understand that, but any ideas you can suggest to do this???
Regards
Mike
Fortune favours the brave, so don't regret on missed oppurtunities.
|
|

November 1st, 2006, 09:46 AM
|
|
Wrox Author
|
|
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
|
|
You might want to try making the entire page a user control, it would be much eaiser to raise events of other objects if you had it that way.
-------------------------
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
^^Thats my signature
|
|

November 1st, 2006, 10:43 AM
|
|
Friend of Wrox
|
|
Join Date: Aug 2004
Posts: 550
Thanks: 0
Thanked 1 Time in 1 Post
|
|
Thanx parsons
Rather than not starting a new thread, can u tell me is it possible to maintain the value of hidden during postback, i.e. I have set some value in a hidden control, now when I press F5, the value of hidden is lost, is this working correct or am I doing something wrong.
Regards
Mike
Fortune favours the brave, so don't regret on missed oppurtunities.
|
|

November 1st, 2006, 10:52 AM
|
|
Wrox Author
|
|
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
|
|
It depends. If it is a dynamic control and you recreate it everytime your form is lost, then you will have to get the value at form post, capture the value, then recreate your control, and then populate the control with your value.
Otherwise, as long as the value is being run as server control, it *should* be participating in view state.
-------------------------
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
^^Thats my signature
|
|
 |