Registering a BizTalk Server custom adapter is easy, but most of the time is not very pleasant because it involves several manual steps. Also, because it is not a common or daily task, we tend to forget how to do certain actions, which forces us to search every time we need to do it.
In my case, I usually don’t remember how to start a command prompt in 64-bit.
Usually, a custom adapter, not a WCF extension used by custom WCF-Adapters, provides a Windows Registry file (.reg). To register the adapter for it to appear on the BizTalk Server Administration Console, we need to:
Now, if you open the BizTalk Administration Console and right-click on the console left tree, BizTalk Server Administration > BizTalk Group > Platform Settings > Adapters, in the Adapter combo-box , you will see the custom adapter that you have just registered.
To simplify the custom adapter registration process, I decided to create a simple PowerShell script to do the trick. Once again, in my case, this is to avoid searching how to run a command prompt in 64-bit every time I need to register a custom adapter.
This PowerShell script will ask you the directory and name of the Windows Registry file (.reg), and after validating its existence, it will ask you if you want to register to run under 32-bit or/and 64-bit host instances.
$questionResult = $windowsShell.popup("Do you want to install this adapter to run under 64-bit Host Instances?", 0,"64-bit Host Instances installation",4) If ($questionResult -eq 6) { # c:\windows\regedit.exe /S $regFilePath reg import $regFilePath /reg:64 Write-Host "Adapter installed as 64-bit." -Fore DarkGreen } $questionResult = $windowsShell.popup("Do you want to install this adapter to run under 32-bit Host Instances?", 0,"32-bit Host Instances installation",4) If ($questionResult -eq 6) { # c:\Windows\syswow64\regedit /S $regFilePath reg import $regFilePath /reg:32 Write-Host "Adapter installed as 32-bit." -Fore DarkGreen }
THIS POWERSHELL SCRIPT IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND.
You can download the PowerShell Script to Register Custom Adapters from GitHub here: