ASP.NET(vb.net) & HTML How to insert HTML code in the asp.net script and asp.net web page with asp class and asp.net style.
ShotDev Focus:
- Insert HTML and asp.net script into asp.net webpage.
Example
ASP Classic Style
AspStyle.aspx
<%@ Page Language="VB" %> <% Response.write ("This is ASP Tag") %> <script runat="server"> Sub Page_Load() Me.txtName.Text = "This is ASP.NET Tag" End Sub </script> <html> <head> <title>ShotDev.Com Tutorial</title> </head> <body> <form runat="server"> <% Response.write("This is ASP Tag<br>") %> <asp:Label id="lblText" runat="server" text="Text"></asp:Label> <asp:TextBox id="txtName" runat="server"></asp:TextBox> </form> </body> </html>
Screenshot
.
.
ASP Classic Style
CodeBehind.aspx
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="CodeBehind.aspx.vb" Inherits="CodeBehind" %> <html> <head> <title>ShotDev.Com Tutorial</title> </head> <body> <form id="form1" runat="server"> <asp:Label id="lblText" runat="server"></asp:Label> </form> </body> </html>
CodeBehind.aspx.vb
Public Class CodeBehind Inherits System.Web.UI.Page Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Load Me.lblText.Text = "ASP.NET Code Behide Style" End Sub End Class
Screenshot
3controlled…
…