In the code area, the first line needs your database connection info. All the rest of the code is generic.
Make a worksheet to hold the sp results
Create a command button to execute the sp.
The code for the command button should have
-------BEGIN CODE------------
ActiveWorkbook.Sheets("
guments WorkSheet>").Activate
Arg1 = Cells(2, 2).Value ' Cells for Arguments
Arg2 = Cells(3, 2).Value
Arg3 = Cells(4, 2).Value
ActiveWorkbook.Sheets("
sultsWorks
heet>").Ac
tivate
RunStoredProcedure "ResultAreaName", "StoredProcedureName", Cells(2, 1), "@Param1", Arg1,"@Param2", Arg2, "@Param3", Arg3
------END CODE
ResultAreaName is used to name the range of the results, use this name for defining your pivottable
Cells(2,1) is the location to put the results in the ResultsWorksheet Anywhere is usually ok unless you are doing a lot of ranges then you need to make sure they don't overlap.