I am still having trouble...

Here is what I am doing..

code:
$DSN="DRIVER={SQL Server};SERVER=$Server;UID=m001kah;PWD=password;DATABASE=PSStartup"
$Statement2 = "exec ff_trips_sp2 'PEYCLE','S','01/20/03','01/20/03'"
;Open connection to DB or at least try... ; )
$OpenConn = DBConnOpen ("$DSN")
If @ERROR <> 0
If @ERROR = -2147352567
$LogLine = @TIME + " - unable to authenticate user $User" + @CRLF
$Write = WriteLine (1,"$LogLine")
$Silent = MessageBox ("Invalid SQL account information.","SMB ERROR : 200", 16)
Exit 200
Else
$LogLine = @TIME + " - general SQL error @ERROR detected." + @CRLF
$Write = WriteLine (1,"$LogLine")
$Silent = MessageBox ("General SQL error @ERROR detected.","SMB ERROR : 201", 16)
Exit 201
EndIf
EndIf

;Execute the stored procedure...
;=====================================================================
$LogLine = @TIME + " - calling stored procedure against db." + @CRLF
$Write = WriteLine (1,"$LogLine")

$ReturnArray = DBGetRecordSet($OpenConn,"$Statement2",4)
If @ERROR <> 0
$WRITEERROR = @ERROR
$WRITEERRORS = @SERROR
$LogLine = @TIME + " - error $WRITEERROR returned from sp." + @CRLF
$Write = WriteLine (1,"$LogLine")
$LogLine = @TIME + " - error $WRITEERRORS returned from sp." + @CRLF
$Write = WriteLine (1,"$LogLine")
$Silent = MessageBox ("Error $WRITEERROR in SP execution - contact admin.", "SMB ERROR : 210", 16)
Exit 210
EndIf

When I get to the part about executing the sp I get the following errors.

Error: -2147352567
SError: error COM exception error "Open" (Microsoft OLE DB Provider for ODBC Drivers - [Microsoft][ODBC SQL Server Driver]Syntax error or access violation) [-2147352567/80020009]

But when I log into QA with this account I have no problems running the sp. Any thoughts on what I am doing?

Thanks for the help thus far.
_________________________
Austin Henderson