Call store procedure
<%@ Page Language=VB Debug=true %> <%@ Import Namespace="System.Data" %> <%@ Import Namespace="System.Data.SQLClient" %> <script runat=server> Sub Page_Load(ByVal Sender as Object, ByVal E as EventArgs) Dim DBConn as SQLConnection Dim DBSP As New SQLCommand DBConn = New SQLConnection("server=yourhost;" _ & "Initial Catalog=TT;" _ & "User Id=sa;" _ & "Password=yourpassword;") DBSP.CommandText = "Exec AddGarbageRecord" DBSP.Connection = DBConn DBSP.Connection.Open DBSP.ExecuteNonQuery() lblMessage.Text = "Stored procedure completed." End Sub </SCRIPT> <HTML> <HEAD> <TITLE>Calling a Stored Procedure</TITLE> </HEAD> <Body LEFTMARGIN="40"> <form runat="server"> <BR><BR> <asp:label id="lblMessage" runat="Server" /> </form> </BODY> </HTML>