Skip to main content
Participating Frequently
May 22, 2007
Question

Session Variable in a Command Object

Hi all,
How would I insert a session variable in place of Request.Form variable in the following code:

<%

Set Command1 = Server.CreateObject ("ADODB.Command")
Command1.ActiveConnection = MM_skilledovertime_STRING
Command1.CommandText = "DELETE FROM Employeedata WHERE last5=?"
Command1.Parameters.Append Command1.CreateParameter("MMColparam", 200, 1, 9, MM_IIF(request.form("last5"), request.form("last5"), Command1__MMColparam & ""))
Command1.CommandType = 1
Command1.CommandTimeout = 0
Command1.Prepared = true
Command1.Execute()

%>
Instead of "(request.form("last5"), "
it would be a (session("last5")

Thanks,
Lenny
This topic is closed to new replies. Start a new post to keep the conversation going.

1 reply

Inspiring
May 22, 2007
I think you've answered your own question really :)

--
Jules
http://www.charon.co.uk/charoncart
Charon Cart 3
Shopping Cart Extension for Dreamweaver MX/MX 2004



Translate