Guest Rohini Posted August 25, 2006 Share Posted August 25, 2006 Hi all, I want to use stored proc in ASP project.And i want to call that stored Proc using Javascript.Plezz help me.Its very urgent.. Following code is in VBscript code but how can i call it in javascript????<%Set objCmd= Server.CreateObject("ADODB.Command")Set objRS= Server.CreateObject("ADODB.Recordset")objCmd.commandText ="UpdateCompWebStatus"objCmd.commandType = 4Set objCmd.ActiveConnection= objConn Set objParam = objCmd.CreateParameter("@del_inqid",200,1,20)objCmd.Parameters.append objParamobjCmd("@inquiryid")=inquiryid call CheckCommandParams( objCmd, "UpdateCompWebStatus")Set objRS=objCmd.execute%>Thanx ..........Please Help....................................... Link to comment Share on other sites More sharing options...
Skemcin Posted August 25, 2006 Share Posted August 25, 2006 Javascript is a client side language and a Stored Procedure is a Database Function (server side). Javascript will not be able to directly execute a stored procedure unless the javascript is calling a page on the server to do it. Link to comment Share on other sites More sharing options...
aspnetguy Posted August 25, 2006 Share Posted August 25, 2006 Set objCmd= new ActiveXObject("ADODB.Command")objRS= new ActiveXObject("ADODB.Recordset");objCmd.commandText ="UpdateCompWebStatus";objCmd.commandType = 4objCmd.ActiveConnection= objConn;objParam = objCmd.CreateParameter("@del_inqid",200,1,20);objCmd.Parameters.append objParam;objCmd("@inquiryid")=inquiryidCheckCommandParams( objCmd, "UpdateCompWebStatus")objRS=objCmd.execute Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now