Maoam
02-04-2004, 06:22 AM
Hi!
I'v got an ADODB.connection object, which is connected to an SQL server. During my command object is executed, the SQL server sends messages. I'd like to write those messages on the screen. There is an event of the adodb.connection objets wich seems to be good for me.
Dim WithEvents Myevent as ADODB.connection = Myconnection
Private Sub Myevent_InfoMessage(ByVal pError As ADODB.Error, ByRef adStatus As ADODB.EventStatusEnum, ByVal pConnection As ADODB.Connection) Handles MYevent.InfoMessage
tbSql.Text = pError.Description
End Sub
But it give only one message. If I execute my command with Queri Analyzer the message will contain ten or more rows. My problem is the following: Why there was only one event in the VB executing?
In the Query Analyzer, The Message rows mean one message which has more rows, or evry rows are a new message?
Any help would be great.
I'v got an ADODB.connection object, which is connected to an SQL server. During my command object is executed, the SQL server sends messages. I'd like to write those messages on the screen. There is an event of the adodb.connection objets wich seems to be good for me.
Dim WithEvents Myevent as ADODB.connection = Myconnection
Private Sub Myevent_InfoMessage(ByVal pError As ADODB.Error, ByRef adStatus As ADODB.EventStatusEnum, ByVal pConnection As ADODB.Connection) Handles MYevent.InfoMessage
tbSql.Text = pError.Description
End Sub
But it give only one message. If I execute my command with Queri Analyzer the message will contain ten or more rows. My problem is the following: Why there was only one event in the VB executing?
In the Query Analyzer, The Message rows mean one message which has more rows, or evry rows are a new message?
Any help would be great.