Monday, January 27, 2014

BizTalk 2013 Installation Bug: Enterprise Single Sign-On Error

While Installing BizTalk I received the following Error that Enterprise Single Sign-On should be installed manually.



Well this had not occured while installing previous versions of BizTalk. So I was a little bit curious as to what am I missing on the Server.
So I started installing the redistributable prerequisites manually as this is what BizTalk installation does first.


What I noticed is 
After installing .Net Framework 4.5 from the .cab file I tried to run the BizTalk installation again as normal and selected the .cab file I downloaded.
And it worked fine and BizTalk 2013 was installed successfully with Enterprise Single Sign-On and all other features.
So seems Enterprise Single Sign-On  installation needs .Net Framework 4.5 to be in  place before it can be installed and BizTalk Installation is messing it up somewhere while installing the redistributable prerequisites.

BAM configuration failure in BizTalk 2013

HI,
Seems the BizTalk 2013 Installation software has not been tested properly.
I got many errors which I could google and fix it but this one was odd about BAM configuration failed with following error.

ERROR: Encountered error while executing command on SQL Server "".A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)The system cannot find the file specified (Microsoft.BizTalk.Bam.CfgExtHelper.Utility)
[ Error BAMConfigWizExt] 

Solution was to install the latest Cumulative update and try again without Server restart and it worked fine and BAM was configured correctly.
BizTalk Cumulative Update Link


Till now Core Product configuration(SSO,Group,Runtime) was not messed up by Microsoft in all versions (2004 till 2010) I installed/configured. I normally used to install Cumulative update after I am done configuring default BizTalk features or maybe it was a wrong way of doing it  :) .

Monday, December 31, 2012

ItemTemplate missing

I had this wierd Error where I could not add a new Orchestration to my project.
I did not find the template for it when I clicked Add New Item.
Luckily I remembered I had installed a hotfix a day before and that could have messd the Template bindings.




























So I knew I had to install only the templates again.
I did it by running the following command as mentioned in the link below and it helped.
http://msdn.microsoft.com/en-us/library/ms241279(v=vs.80).aspx
devenv.exe /InstallVSTemplates























I restarted Visual Studio and my templates were back again. 

Wednesday, November 21, 2012

BizTalk 2013 Beta released!

The BizTalk Server Team recently announced the arrival of the new beta version of the next generation of Integration Product of BizTalk Server called BizTalk Server 2013.
Its a major release lined up with SQL 2012,Visual Studio 2012,Windows 2012.
For more information read here.
http://blogs.msdn.com/b/biztalk_server_team_blog/archive/2012/11/06/announcing-biztalk-server-2013-beta.aspx

Wednesday, October 3, 2012

BAM Add-In Excel Issue : Unspecified Automation Error


"Unspecified Automation Error" when Opening Excel using BAM Addin.

Fixit Available
There is a fixit available for this problem:
Office 2010 w SP1 - http://support.microsoft.com/kb/2597986
Office 2007 w SP2 or SP3 - http://support.microsoft.com/kb/2687441
Office 2003 w SP3 or Office 2003 Web Components w SP3 - http://support.microsoft.com/kb/2687323

Steps to fix the problem manually
The manual fix for this problem is to re-register MSCOMCTL.OCX. To do this, follow these steps:

1. Open an administrative-level command prompt. The command prompt MUST be on the administrative level for this to work. Click START, and type RUN in the run command line. On Windows Vista and Windows 7 you will see CMD.EXE appear in the quick search list. Right click CMD.EXE and left click Run As Administrator. A black command prompt opens. On Windows XP, there is no built-in run-as-admin, but you can use the run as menu option (or runas command line) to execute an admin command from a Limited User Account.

2. If on a 64-bit machine, type the following:
regsvr32.exe /u  C:\Windows\SysWOW64\MSCOMCTL.OCX

Hit ENTER

then type
regsvr32.exe  C:\Windows\SysWOW64\MSCOMCTL.OCX

If on a 32-bit machine, type the following:
regsvr32.exe /u C:\Windows\System32\MSCOMCTL.OCX

Hit ENTER

then type
regsvr32.exe C:\Windows\System32\MSCOMCTL.OCX

Your Excel  BAM Addin should work again after doing this.

FYI,

Sunday, June 24, 2012

Business Rule Engine: Database Lookup, .Net Helper Class

I was googling for a blog article which could show me  the simplest way of implementing BRE Rules with Database lookup and .net Helper Class. Most of the samples talk of writing everything in a Helper Class with logic to call the Rule. Rest talk of using Facts to pass on the .net Helper Class Instance. Some samples are limited to only Rule Store.....but not about how to call it from Orchestration.

Here I would like to discuss a simple common situation which one comes across while implement Rules in BRE.

In the Screenshot below I have 2 Rules which lookup 2 different tables.
I also have a .net Helper Class method just to convert the string Xml field to GUID since the AccountID  field in the table is of Type GUID and the Xml field is of type string.






















The Rules are easy to construct...Just Drag/Drop fields from the XML Schema and the Database table and the XML Helper Class.
The Xml Static Helper Class works in the Business Rules if we add the following Registry key or else the Rules will get executed but the BRE will not output any Error and the HelperClass condition will be skipped.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\BusinessRules\3.0\StaticSupport (DWORD)
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\BusinessRules\3.0\StaticSupport (DWORD)



To test the Policy ...right click the Version and click Test Policy. Add instance of all inputs(Databases/Xml File but not of .Net Helper Class(It will read from GAC).Now on Click of Test button the Rule will be executed and the Input Xml file will be modified and will act as the Ouput file.


































Lets look into how to call the Rule from the Orchestration and the code in the Xml Helper Class.
Call Rules Shape only work in Atomic Shape Scope, So we need to add the Scope and set it to Atomic in the Scope Properties.

I have add the Expression shape where I set the input parameters to the Call Rules Shape.
SQLConn is the connection to the Database which is used in the Input.
RulesDataConn is the input parameter for the table.
Northbound is a dummy database I have used which contains a table called CustomerAddressBase and AccountExtensionBase.
I am using these 2 tables in 2 different Rules.
I also created the variable for .Net Helper class and pass it on to the Call Rules Shape as below.
Here is is how it looks in the configuration of Call Rules Shape.
Now we have Configured the Orchestration. Below I will show you the type of Variables used above.

Here is the code of the .Net Helper Class which just converts the string from the Xml field to GUID field.
Note: The Helper Class should be static and Serializable as it used in Atomic Shape.
We do not need to create Facts as we are using Static Methods in the Helper Class.


Deploy the Rule from the Rule Store and Deploy the Orchestration and GAC the Helper Class.
After deployment link the Policy to the Application in BizTalk Admin Console.

Now drop the file and Rules should be executed and the Xml file will be created.
This tutorial is just for reference and not a Sample Lab to be followed. It will just help you if you missed any steps in your Project.

Microsoft has many good Samples but without any proper documentation to explain the steps involved ...it only has deployment and test guide to test the Sample.
Hope this guide helps you in implementing BRE using Microsoft Business Rule Composer.

Thursday, June 14, 2012

BAM Add-In Excel Issue : Object library invalid or contains references to object definitions that could not be found.

Recently when I opened Excel every time I got a weird Error for BAM Add-In.
Incidently I have not messed up with BAM recently for sure.  After googling a bit I could not find any post related to BAM Add-In issue but many with VBA macros failing after a Cumulative update.
My laptop is set to auto update the system with latest updates as I love to try new features out in Microsoft market and this Cumulative update had messed up the macro settings in Excel.
http://support.microsoft.com/kb/957924/en-us

The point here is if you get Errors related to BAM Add-In Excel macro while opening Excel just follow these steps
To resolve the problem, delete cached versions of the control type libraries. 
To do this, search the hard disk for “.exd,” and then delete all occurrences. The .exd files are re-created automatically by using the new controls the next time that you use VBA.

After deleting all .exd files(there were only 2 in AppData folder) things were back to normal and BAM Excel Add-In worked fine.