Extract details of resources contained within a BizTalk MSI package

Posted on

There are multiple ways to extract details of resources contained within a BizTalk MSI package. One being using msiexec.exe to extract the contents to a location and get the information.

However BizTalk has an excellent dll which can help get all the required resource details that comes in packed in the MSI package.

The saviour here is

Microsoft.BizTalk.ApplicationDeployment.dll that comes with BizTalk installation.

Two dlls are required to be referenced :

1. Microsoft.BizTalk.ApplicationDeployment.dll which has the method that scans for you the MSI for all its resources and then the related properties within each resource. Its placed under the root BizTalk installation folder.

2.Microsoft.BizTalk.Admin.dll from GAC


 Microsoft.BizTalk.ApplicationDeployment.IInstallPackage pack = null;

pack = Microsoft.BizTalk.ApplicationDeployment.DeploymentUnit.ScanPackage(“FullBizTalkMSIPath”);

// Gets all the information about all the resources compliled witin BizTalk MSI package

Microsoft.BizTalk.ApplicationDeployment.IDeploymentResource[] resources = pack.Resources;

foreach (var resource in resources  )

{    // Do something     }


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s