Using Sandcastle inside VS2010

Topics: Developer Forum
Nov 8, 2010 at 12:41 PM

Hello,

I need to use Sandcastle to automatically generate CHM file during build process inside VS2010. I mean on using Post-build event.

I've read the article about using Sandcastle inside VS2010 at this address:

http://www.ewoodruff.us/shfbdocs/html/8ffc0d37-0215-4609-b6f8-dba53a6c5063.htm

But it's not clear for me.

Take a look at the instructions in Post-build edit field:

ECHO Building SHFB help file via MSBuild
"$(SystemRoot)\Microsoft.NET\Framework\v3.5\MSBuild.exe"
    /p:CleanIntermediates=True /p:Configuration=Release
    "$(SolutionDir)Doc\SandcastleBuilder.shfbproj"

I don't understand last line:

$(SolutionDir)Doc\SandcastleBuilder.shfbproj

Should I create SandcastleBuilder.shfbproj file before I use it inside VS2010? If so, I don't need that way. When I run the build process, GUI builder opens. I need the way of creation CHM file without opening GUI builder at all. How can I do that?

Thank you in advance.

Goran

 

Nov 8, 2010 at 1:53 PM

I'm doing this:

1) Open Sandcastle Help File Builder.

2) Create new project and name it GetOracleData.shfbproj.

3) Add project's XML file to "Documentation Sources" along with project's DLL.

4) Save the project and close Sandcastle Help File Builder.

5) Open VS2010 and open my project there.

6) Write this instruction in Post-build field:

"$(SystemRoot)\Microsoft.NET\Framework\v3.5\MSBuild.exe" /p:CleanIntermediates=True /p:Configuration=Debug "$(SolutionDir)Doc\GetOracleData.shfbproj"

7) Save my project in VS2010.

8) Build the project.

It works fine.

 

I'd like to not open Sandcastle Help File Builder and add XML and DLL files manually. Is this possible?

 

Coordinator
Nov 9, 2010 at 3:48 PM

Currently, SHFB does not support VS2010 project files as documentation sources since it's still built against MSBuild 3.5.  For the time being you do need to add the assemblies and comments files manually as documentation sources.

Eric