Hi Eric,
right after the lines in the BuildSolutionConfig
while(solutionBuild.BuildState != vsBuildState.vsBuildStateDone);
where we wait for the build to finish. You can grab the output from the
output pane. Here is a quick macro that you can translate into C#.
Sub BuildWindowText()
Dim outputWin As OutputWindow
Dim outputWinPane As OutputWindowPane
Dim outputWinPaneTxtDoc As TextDocument
outputWin =
DTE.Windows.Item(EnvDTE.Constants.vsWindowKindOutp ut).Object
outputWinPane =
outputWin.OutputWindowPanes.Item("{1BD8A850-02D1-11D1-BEE7-00A0C913D1F8}")
outputWinPaneTxtDoc = outputWinPane.TextDocument
MsgBox(outputWinPaneTxtDoc.StartPoint.CreateEditPo int().GetText(outputWinPan
eTxtDoc.EndPoint))
End Sub
Instead of a msgbox, you can look at some other reporting mechanism.
I hope that helps.
Thanks!
Mike Wong
Microsoft Developer Support
--------------------
Content-Class: urn:content-classes:message
From: "Eric Chong" <ec********@hotmail.com>
Sender: "Eric Chong" <ec********@hotmail.com>
Subject: BuildIt tool: How can I get a build error description?
Date: Tue, 2 Dec 2003 16:27:18 -0800
Lines: 11
Message-ID: <06****************************@phx.gbl>
MIME-Version: 1.0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
thread-index: AcO5NDWUxyNzmfucTqiT5l91akPTgg==
Newsgroups: microsoft.public.dotnet.general
Path: cpmsftngxa06.phx.gbl
Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.general:117239
NNTP-Posting-Host: tk2msftngxa09.phx.gbl 10.40.1.161
X-Tomcat-NG: microsoft.public.dotnet.general
I have been trying to automate our builds using BuildIt
tool available from Microsoft. This tool only log whether
build is success or fail. Since all developers would like
to see what the build error descriptions are, I need to
add it to the source code. However, SolutionBuild object
don't have that property available. Is it even possible to
get that information? What should I do in order to get an
error description?
Thanks in advance.
Eric