Anybody has a suggestion?
Set cmd = New ADODB.Command
With cmd
.ActiveConnection = cn400
.CommandText = "SELECT max(PRJNBR) FROM ENPRAWD02.PRJPF"
.CommandType = adCmdText
Set objRecordset = New ADODB.Recordset
objRecordset.CursorLocation = adUseServer
objRecordset.Open cmd, , adOpenForwardOnly, adLockReadOnly
With objRecordset
Set wrkProjectNumber = .Fields("PRJNBR" It kick an error on this line
End With
End With
Thanks
Set cmd = New ADODB.Command
With cmd
.ActiveConnection = cn400
.CommandText = "SELECT max(PRJNBR) FROM ENPRAWD02.PRJPF"
.CommandType = adCmdText
Set objRecordset = New ADODB.Recordset
objRecordset.CursorLocation = adUseServer
objRecordset.Open cmd, , adOpenForwardOnly, adLockReadOnly
With objRecordset
Set wrkProjectNumber = .Fields("PRJNBR" It kick an error on this line
End With
End With
Thanks