Object doesn't support this property or method: 'Open'
Jeg får følgende fejlmeddelelse:Object doesn't support this property or method: 'Open'
/workstatistics/index.asp, line 27
Min kode ser sådan her ud:
If Request.Form("WhatWasChosen") = "ConvertNowChosen" Then
Set objConn = Server.CreateObject("ADODB.Connection")
strConnString = "Provider=SQLOLEDB;" & _
"Persist Security Info=FALSE;" & _
"USER ID=sa;" & _
"Password=pb16950;" & _
"Initial Catalog=Workstatistics;" & _
"Initial File Name = C:\Programmer\Microsoft SQL Server\MSSQL\" & _
"DATA\WorkStatistics_Data.mdf;"
objConn.Open strConnString
strSQL = "SELECT Arbejdstimer_IN, Primary_Key_BI FROM WorkProjects_T"
objRS = Server.CreateObject("ADODB.Recordset")
objRS.Open strSQL, objConn, AdOpenStatic, AdLockOptimistic, AdCmdText
objRS.MoveFirst
strSQL = "UPDATE WorkProject_T SET Arbejdstimer_IN = '" & intMin & "'" & _
" WHERE Primary_Key_BI = '" & intPrimaryKey & "'"
Do While Not ObjRS.EOF
intHours = objRS("Arbejdstimer_IN")
intMin = intHours * 60
intPrimaryKey = objRS("Primary_Key_BI")
objConn.Execute (strSQL)
objRS.MoveNext
Loop
objRS.Close
Set objRS = Nothing
objConn.Close
Set objConn = Nothing
End If
Hvad er der galt?