borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Previous Topic (ADO SQL problem)Next Topic (How to restore a database) New Topic New Poll Post Reply
AndreaVB Forum : Database : trapping dts status
Poster Message
boit
Level: Scholar

Registered: 28-04-2005
Posts: 43

icon trapping dts status

1. i have an sql-dts module called in vb. how can i know if the sql-dts module has completed its purpose when executed in vb?  as i understand it, vb sends this module as a batch of command to the sql-database, then sql-database processes the batch asynchronously.  the next line of command in vb is triggered independent of the result of the sql-dts module batch.
can i trigger succeeding lines of commands when i know that the sql-dts module completes first?

2. likewise, in executing a shell command.  can i know if the shell command is completed first before i proceed with other lines of commands?

thanks in advance

21-07-2005 at 01:22 AM
View Profile Send Email to User Show All Posts | Quote Reply
steve_w
Level: Moderator


Registered: 18-04-2003
Posts: 1156
icon Re: trapping dts status

Hi

I think I can help you with the dts bit.

If you declare your dts package as below
Option Explicit

Private WithEvents dtsp As DTS.Package


then you will get the following events available
Private Sub dtsp_OnError(ByVal EventSource As String, ByVal ErrorCode As Long, ByVal Source As String, ByVal Description As String, ByVal HelpFile As String, ByVal HelpContext As Long, ByVal IDofInterfaceWithError As String, pbCancel As Boolean)

End Sub

Private Sub dtsp_OnFinish(ByVal EventSource As String)

End Sub

Private Sub dtsp_OnProgress(ByVal EventSource As String, ByVal ProgressDescription As String, ByVal PercentComplete As Long, ByVal ProgressCountLow As Long, ByVal ProgressCountHigh As Long)

End Sub

Private Sub dtsp_OnQueryCancel(ByVal EventSource As String, pbCancel As Boolean)

End Sub

Private Sub dtsp_OnStart(ByVal EventSource As String)

End Sub


Steve  

21-07-2005 at 11:13 AM
View Profile Send Email to User Show All Posts | Quote Reply
boit
Level: Scholar

Registered: 28-04-2005
Posts: 43
icon Re: trapping dts status

Thanks Steve.More success to you

21-07-2005 at 10:39 PM
View Profile Send Email to User Show All Posts | Quote Reply
AndreaVB Forum : Database : trapping dts status
Previous Topic (ADO SQL problem)Next Topic (How to restore a database) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
Partners: Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder