Hello,
I need to know how to call a SQL SP asynchronously in VB.NET (ADO.NET), so my program doesn’t freeze whilst waiting . In VB6 I used to do the following:
Dim cmd as adodb.command
Dim rs as adodb.recordset
Set cmd = new adodb.command
cmd.activeconnection = cn
cmd.commandtext = “EXECUTE mysp_StoredProcedure”
set RS = cmd.execute(,,adAsyncExecute)
do while cmd.state = 4
doevents
loop
Please help.
Thanks
Matt.
I need to know how to call a SQL SP asynchronously in VB.NET (ADO.NET), so my program doesn’t freeze whilst waiting . In VB6 I used to do the following:
Dim cmd as adodb.command
Dim rs as adodb.recordset
Set cmd = new adodb.command
cmd.activeconnection = cn
cmd.commandtext = “EXECUTE mysp_StoredProcedure”
set RS = cmd.execute(,,adAsyncExecute)
do while cmd.state = 4
doevents
loop
Please help.
Thanks
Matt.