How to run Stored Procedure from a Form

A

Agus Budianto

Just a simple question

How to run Stored Procedure from a Form

I am new to Access Project.
My Access Project is connected to SQL Server.

Any answer is highly appreciated.

Rgds,
Agus Budianto
 
A

Alex White MCDBA MCSE

Hi,

if you are trying to run a stored procedure without returning data.

1. docmd.runSQL("EXEC storedprocedurename")

2. currentproject.connection.execute("EXEC storedprocedurename")

if you are trying to return records then

adoTable.open "myStoredProcedureName", currentproject.connection,
cursortype, locktype

Hope it helps.
 
Top