Find articles on computer software, programming, ASP.net, Sql server, databases, C#, websites, Internet, Windows, Outlook macros.
In Asp.Net 4, I have a user control for putting an email address on the page. The control looks like this.
<my:email ...>Any Text</my:email>
The problem is I get the error message
Content is not allowed between the opening and closing tags for element 'email'.
I decorated the control and property with attributes as follows, which got rid of the error message.
[ AspNetHostingPermission(SecurityAction.Demand, Level = AspNetHostingPermissionLevel.Minimal), AspNetHostingPermission(SecurityAction.InheritanceDemand, Level = AspNetHostingPermissionLevel.Minimal),DefaultProperty("Inner_Text"),ParseChildren(true, "Inner_Text"),PersistenceMode(PersistenceMode.InnerDefaultProperty),ToolboxData("<{0}:email_Control runat=\"server\"> </{0}:br_email_Control>") ]public class br_email_Control ... {...[PersistenceMode(PersistenceMode.InnerDefaultProperty),DesignerSerializationVisibility (DesignerSerializationVisibility.Content)]public string Inner_Text { get ... set ... }...}
Name (required)
Email (required)
Website
Notify me of followup comments via e-mail
AWeber Email List Marketing Test Drive
Use email marketing to convert targeted subscribers to customers. Let the system sell itself for you!