Skip to content

ExecSqlProc

Summary

Executes a Stored Procedure with a given parameter and returns a string with the result.

If an error occurs, it will be returned in the string.

The Procedure also needs to be authorised. See CExecStoredProc function for more details.

Example

  ds = Range("SERVER_NAME").Value
  sp = Range("SP").Value
  myParams = Range("PARAMS").Value

  Range("A5:H103").Clear

  t = Now()

  Dim val
  With Application.COMAddIns("Calumo.ExcelClient").Object
    val = .ExecSqlProc(ds, sp, myParams)
  End With

  Range("A5").Value = val
Back to top