Instructions

  1. Put the Microsoft command line transformation utility (msxsl.exe) file in the same folder as the BizTalkMapDocumenterHTML.xslt
  2. In the command prompt, navigate to the folder containing the msxsl.exe file
  3. Run and a command like the following:
  4. Either create an HTML file for a single btm map file:
  msxsl "..\..\..\Source\Acme\Integration\Maps\SouceSystemA\MyMap.btm" BizTalkMapDocumenterHTML.xslt -o "MyMap.btm.html"
  for %%f in ("..\..\..\Source\Acme\Integration\Maps\SouceSystemA\*.btm") do call msxsl "%%f" BizTalkMapDocumenterHTML.xslt -o "%%~nf.btm.html"
<Target Name="CreateBizTalkMapDocumentation">
	<!-- Identify all of the map files - we'll include the project directories of all BizTalk projects, just to be sure -->
	<CreateItem Include="%(BizTalkProject.ProjectDir)\**\*.btm">
              <Output TaskParameter="Include" ItemName="BizTalkMapFiles"/>
        </CreateItem>
	<Message Text="BizTalk Server maps to document: @(BizTalkMapFiles)"/>
        <!-- Re-create the folder to hold the maps -->
	<RemoveDir Condition="Exists('$(MapDocumentationRoot)')" Directories="$(MapDocumentationRoot)" />
	<MakeDir Directories="$(MapDocumentationRoot)" />
	<!-- All the HTML files are written to a single folder, which assumes that each .btm file has a unique filename! -->
	<Exec Command='"$(MapDocumenterDir)\msxsl" "%(BizTalkMapFiles.FullPath)" "$(MapDocumenterDir)\BizTalkMapDocumenterHTML.xslt" -o "$(MapDocumentationRoot)\%(BizTalkMapFiles.Filename).html"' />
</Target>