Re: Data Project - Running SP via ADO



Accepted.
Now, did my post help or not? :-)

Kyle Jedrusiak wrote:
Sorry for the double post.

"Bob Barrows [MVP]" <reb01501@xxxxxxxxxxxxxxx> wrote in message
news:uPWpkfWyHHA.4928@xxxxxxxxxxxxxxxxxxxxxxx
Kyle Jedrusiak wrote:
I've looked at the ADO documentation and it's not clear to me.

I have a long SP that doesn't return any records.

I want the ability to start running it, know that it's still running
so I can let the user know and be able to stop any time after it's
been started.

I am using the CurrentProject.Connection to run the SP.

I've tried both the Connection object and the Command object.

When I call the Cancel method, the SP continues to run till it's
done. If there is a way to do this correctly, what it is?

You need to run it asynchronously by instantiating the Connection
object with the WithEvents keyword. I do not know if this is
possible with CurrentProject.Connection: I doubt if it is, but you
will need to ask the Access people if it is.

Start here:
http://msdn2.microsoft.com/en-us/library/ms677579.aspx

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get
a quicker response by posting to the newsgroup.

--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"


.



Relevant Pages

  • Re: Updating column property on table gives error
    ... in code instead of when the append happens. ... Please reply to the newsgroup. ... This email account is my spam trap so I ...
    (microsoft.public.data.ado)
  • Re: Writing a GUID to a SQL table
    ... I strongly suspect that it is SQL Server, ... >> Please reply to the newsgroup. ... This email account is my spam trap so I ...
    (microsoft.public.inetserver.asp.db)
  • Re: VBSCript execute MS SQL Stored Procedure Return Value
    ... Microsoft MVP -- ASP/ASP.NET ... Please reply to the newsgroup. ... This email account is my spam trap so I ...
    (microsoft.public.scripting.vbscript)
  • Re: using ado drivers with 64 bits software
    ... experts in one of the Access groups. ... Microsoft MVP -- ASP/ASP.NET ... Please reply to the newsgroup. ... This email account is my spam trap so I ...
    (microsoft.public.data.ado)
  • Re: move table
    ... Microsoft MVP - ASP/ASP.NET ... Please reply to the newsgroup. ... This email account is my spam trap so ...
    (microsoft.public.inetserver.asp.db)