DataBind method example : Property Binding « Data Binding « ASP.Net






DataBind method example

<%@ Page Language="vb" %>
<html>
   <head>
      <title>DataBind method example</title>
      <script runat="server">
         Dim Color As System.Drawing.Color = System.Drawing.Color.Red
         Sub Page_Load()
            Message.Text = "ForeColor is: " & Color.Name
            DataBind()
         End Sub
      </script>
   </head>
<body>
   <asp:label id="Message" ForeColor="<%# Color %>" runat="server"/>
</body>
</html>

 








Related examples in the same category

1.Color Property binding