I've successfully implemented disabling controls in a repeater in a master page's content from the master page's page load function but it does not work when the repeater uses a datasource that has a querystringparameter. If i change the Sqldatasource's
select command with an explicit where statement then the disabling of the controls works fine. And also, the function that I wrote works when being called from the content page's page load function but not from the master page's page load. Any suggestions
on how I could make this happen from the master page? Thanks!
So i went a completely different route and stuck a transparent image over my window so that people can't click into the controls. I'd still like to know a solution if anybody has any ideas
Parameters on DataSource Controls can cause DataBinds when you don't expect them. Better move the code for disable to a place that is related to DataBinding. The DataBound handler would be a good choice.....if Repeater had it. In the ItemDataBound handler
you can do it for each item individually....if it weren't for the fact that the MasterPage may not be able to subscribe to it.
How does the MasterPage access the Repeater now?
Superguppie.
Please remember to click “Mark as Answer” on the post that helps you. This can be beneficial to other community members reading the thread.
When all you've got is a Hammer, Every Problem looks like a Nail. Michael Swain.
equinoxiq
Member
2 Points
4 Posts
Disable Controls in Repeater from A Master Page
Mar 01, 2012 03:47 PM|LINK
Hello everyone
I've successfully implemented disabling controls in a repeater in a master page's content from the master page's page load function but it does not work when the repeater uses a datasource that has a querystringparameter. If i change the Sqldatasource's select command with an explicit where statement then the disabling of the controls works fine. And also, the function that I wrote works when being called from the content page's page load function but not from the master page's page load. Any suggestions on how I could make this happen from the master page? Thanks!
equinoxiq
Member
2 Points
4 Posts
Re: Disable Controls in Repeater from A Master Page
Mar 01, 2012 05:47 PM|LINK
So i went a completely different route and stuck a transparent image over my window so that people can't click into the controls. I'd still like to know a solution if anybody has any ideas
superguppie
All-Star
48225 Points
8679 Posts
Re: Disable Controls in Repeater from A Master Page
Mar 02, 2012 01:09 PM|LINK
Parameters on DataSource Controls can cause DataBinds when you don't expect them. Better move the code for disable to a place that is related to DataBinding. The DataBound handler would be a good choice.....if Repeater had it. In the ItemDataBound handler you can do it for each item individually....if it weren't for the fact that the MasterPage may not be able to subscribe to it.
How does the MasterPage access the Repeater now?
Please remember to click “Mark as Answer” on the post that helps you. This can be beneficial to other community members reading the thread.
When all you've got is a Hammer, Every Problem looks like a Nail. Michael Swain.