When developing Commerce Server Pipeline Components one of the biggest issues people face is the lack of description you receive when they throw exceptions. One of the most confusing error messages you can receive however is:
Pipeline Error: Component Execution failed for component[0x2] hr: 0x0
CLSID: {2E71930F-3B01-403D-B601-E31F5BDFBD24} Could not create Component . This may be a component registration issue
What's more confusing is this error is relatively simple to correct. The actually exception is thrown – not because of a fault in the code, but simply because your are trying to deploy a 64bit component using 32 bit tools.
If you receive this error using when working on a x64 machine, please ensure your post-build script is similar to the following:
1: set REGASM=C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\regasm.exe
2: set GACUTIL="C:\Program Files\Microsoft SDKs\Windows\v6.0A\Bin\gacutil.exe"
3: %GACUTIL% /I $(TargetPath)
4: %REGASM% $(TargetPath) /tlb:$(TargetDir)$(TargetName).tlb
Note: the regasm.exe is from the Framework64 directory.