Executing Script or Cmd after BTDF Undeployment

Topics: General Questions, Server Deployment
Jun 20, 2012 at 3:17 PM

I have successfully added a custom deployment step after a biztalk BTDF deployment with the syntax after the  <Import Project="$(DeploymentFrameworkTargetsPath)BizTalkDeploymentFramework.targets" /> tag in the btdfproj file.


<Target Name="CustomDeployTarget">
    <Exec Command="[the command to execute]" />

However, I was wondering how I could add a similar command to be run after an undeployment?

Thanks for the help,



Jun 20, 2012 at 4:01 PM


CustomDeployTarget runs early in the deployment, not after.  There is a CustomUndeployTarget which similarly runs early in the undeployment process.  In the final version of 5.0 there will be post-deploy and undeploy targets too.  If you are using BizTalk 2010, you can also use the AfterTargets and BeforeTargets attributes on your target to slot it into the execution whenever you want.


Jun 20, 2012 at 4:14 PM

Worked perfectly, thanks for your help.