By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,454 Members | 3,208 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,454 IT Pros & Developers. It's quick & easy.

Web User Controls (Setting properties dynamically)

P: n/a
Hi everyone,

I have the following web user control. I like to set the properties
dynamically without using page.databind.

<uc1:partnerdownloads id="Partnerdownloads1" PropDomain="<%= Domain %>"
PropPartnerUserGroupID="<%= PartnerUserGroupID %>"
runat="server"></uc1:partnerdownloads>

However, and <%= Domain %>
and <%# Domain %>

failed.

I have declared Domain as a public. Could someone please tell me how to
fix this?

Thanks
Maz.

Feb 16 '06 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Hi,
Setting properties can be dynamically achieved using the following code..

((WebUserControl1)Partnerdownloads1).PropDomain= "your value";
((WebUserControl1)Partnerdownloads1).PropPartnerUs erGroupID= "your value";

WebUsercontrol1 is the ascx( user control) name..

Hope this would help..

-Baskar-
"ma*******@gmail.com" wrote:
Hi everyone,

I have the following web user control. I like to set the properties
dynamically without using page.databind.

<uc1:partnerdownloads id="Partnerdownloads1" PropDomain="<%= Domain %>"
PropPartnerUserGroupID="<%= PartnerUserGroupID %>"
runat="server"></uc1:partnerdownloads>

However, and <%= Domain %>
and <%# Domain %>

failed.

I have declared Domain as a public. Could someone please tell me how to
fix this?

Thanks
Maz.

Feb 17 '06 #2

P: n/a
Hi BASKAR BV is there any way to write the property of the ascx and change it
from the properties windows (Designer view) ????????

"BASKAR BV" wrote:
Hi,
Setting properties can be dynamically achieved using the following code..

((WebUserControl1)Partnerdownloads1).PropDomain= "your value";
((WebUserControl1)Partnerdownloads1).PropPartnerUs erGroupID= "your value";

WebUsercontrol1 is the ascx( user control) name..

Hope this would help..

-Baskar-
"ma*******@gmail.com" wrote:
Hi everyone,

I have the following web user control. I like to set the properties
dynamically without using page.databind.

<uc1:partnerdownloads id="Partnerdownloads1" PropDomain="<%= Domain %>"
PropPartnerUserGroupID="<%= PartnerUserGroupID %>"
runat="server"></uc1:partnerdownloads>

However, and <%= Domain %>
and <%# Domain %>

failed.

I have declared Domain as a public. Could someone please tell me how to
fix this?

Thanks
Maz.

Feb 20 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.