jdccr

I have WinXP Pro SP2 and VS2005 SP1.

I'm converting my projects from VS2003 to VS2005 and I receive a lot of warnings in several projects. For example, to one of my projects (for example MyProject.vbproj) I receive the following result in the command prompt:

Build succeeded:

...

... (a lot of warnings)

...

95 Warnings(s)
0 Errors

Time elapsed 00:00:00.61

But, I'm creating and application in VB2005 that use MSBuild of the following way:

MyProcess = New Process

MyProcess.StartInfo.FileName = "..\..\msbuild.exe"

MyProcess.StartInfo.Arguments = "MyProject.vbproj /t:Rebuild /p:Configuration=Release"

MyProcess.StartInfo.CreateNoWindow = True

MyProcess.StartInfo.UseShellExecute = False

MyProcess.StartInfo.RedirectStandardOutput = True

MyProcess.Start()

MyProcess.WaitForExit()

When I run my application the program stops in the instruction WaitForExit() and not responding, but if I change the properties of MyProject.vbproj and disable all the warnings my application works.

Please, help me.



Re: Visual Studio Team System - Testing Problem with MSBuild and Warning notification

jdccr

I found the solution to my problem...

After of the instruction WaitForExit() I had the instruction: cResult = MyProcess.StandardOutput.ReadToEnd

I resolved my problem of the following way:

MyProcess.Start()

cResult = MyProcess.StandardOutput.ReadToEnd

MyProcess.WaitForExit()

I discovered that my problem was related with the buffer of MyProcess...

More details in: http://msdn2.microsoft.com/en-us/library/system.diagnostics.process.standardoutput(VS.71).aspx