You could build a class that you call to run the stored procs. It could set up
the event-handler to catch the InfoMessage event, and package up the result it
gets (or nothing, if the event doesn't fire) into a result for you.
I don't know how much code you write for each stored proc call that y
> ignore me
> if i actually read your post fully i'd would have noticed you are not
> looking to rewrite the sprocs.
> sorry
No worries. Of course, you're right, as is Curt. It would be far better to
fix the problem now than to code a work around for it. I could make a case
to the managemen
OTNET@DISCUSS.DEVELOP.COM
Subject: Re: [ADVANCED-DOTNET] Capture output of T-SQL PRINT 'text'
Statement using ADO.NET
use @Success as an output parameter and in calling code look at it's value
to work out what to show to the user.
-Original Message-
From: Discussion of
use @Success as an output parameter and in calling code look at it's value
to work out what to show to the user.
-Original Message-
From: Discussion of advanced .NET topics.
[mailto:[EMAIL PROTECTED] Behalf Of Doug Wilson
Sent: Thursday, June 21, 2007 7:03 PM
To: ADVANCED-DOTNET@DISCUSS.D
> > Is there any way in ADO.NET to capture the ouput of the PRINT
statements?
> You want to look at the SqlConnection.InfoMessage event.
>
> But really, isn't this what regular expressions and "find/replace"
> were invented for? :P
If only it were that simple. ;)
The SqlConnection.InfoMessage ev
On 6/21/07, Doug Wilson <[EMAIL PROTECTED]> wrote:
Is there any way in ADO.NET to capture the ouput of the PRINT statements?
You want to look at the SqlConnection.InfoMessage event.
But really, isn't this what regular expressions and "find/replace" were
invented for? :P
--
Curt Hagenlocher