tacobell1234
asked on
Cursortype management with Dreamweaver CS3
Hello,
I recently upgraded to CS3 from Dreamweaver MX and was surprised to discover that the automatic coding for Recordsets had changed quite a lot. The software now generates commands rather than recordsets. (SEE BELOW)
Problem is, the default cursortype generated by the new code is obviously not the one I need (ie '1'), and some fields in my asp page aren't getting populated.
Would anyone know how to get Dreamweaver CS3 to kindly let me choose my cursortype, and lacking this, how to change it manually ?
I recently upgraded to CS3 from Dreamweaver MX and was surprised to discover that the automatic coding for Recordsets had changed quite a lot. The software now generates commands rather than recordsets. (SEE BELOW)
Problem is, the default cursortype generated by the new code is obviously not the one I need (ie '1'), and some fields in my asp page aren't getting populated.
Would anyone know how to get Dreamweaver CS3 to kindly let me choose my cursortype, and lacking this, how to change it manually ?
Set Recordset7 = Server.CreateObject("ADODB.Recordset")
Recordset7.ActiveConnection = MM_ttt_STRING
Recordset7.Source = "SELECT * FROM fff WHERE fff = " + Replace(Recordset7__MMColParam, "'", "''") + ""
Recordset7.CursorType = 1
Recordset7.CursorLocation = 2
Recordset7.LockType = 1
Recordset7.Open()
became this:
Set Recordset1_cmd = Server.CreateObject ("ADODB.Command")
Recordset1_cmd.ActiveConnection = MM_ttt_STRING
Recordset1_cmd.CommandText = "SELECT * FROM tttt WHERE ID_tttt = ?"
Recordset1_cmd.Prepared = true
Recordset1_cmd.Parameters.Append Recordset1_cmd.CreateParameter("param1", 5, 1, -1, Recordset1__MMColParam) ' adDouble
Set Recordset1 = Recordset1_cmd.Execute
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.