here is the code.
If Page.IsPostBack Then
' This would retrieve the property value when the form is
postback
TextBox2.Text = TextBox1.Attributes.Item("Audit")
End If
' This would add the audit property to the textbox
TextBox1.Attributes.Clear()
TextBox1.Attributes.Add("Audit", "1")
Dim myHttpResponse As HttpResponse = Response
Dim myHTMLTextWriter As New HtmlTextWriter(myHttpResponse.Output)
' This is to write the property to the html tag
TextBox1.Attributes.AddAttributes(myHTMLTextWriter)
i've tried this and it worked. hope this would solve your problem.
Regards
--
Sarmad Aljazrawi
B.Sc. Computer Science, MSDBA, MCP
www.aljazrawi.net
Dave said:
I'm new to asp.net and here's what I'm hoping to do. I want to create a
control that uses the textbox control (inherits from?) and adds a new
property called "Audit" to it. I then want to use this new textbox on a new
webpage and be able to set the Audit property.