Hi,
We have an asp.net webapi project (.net 4.0) where we use a custom xdt Transform to manipulate some values in our web.config. Our development environment is Visual Studio 2012.
Until we installed VS 2012 Update 4 we were fine, however when we did that it brought WebDeploy 3.5 with itself and now our publishes fail at the web config transformation step with the following error message: "'xxxxx' is not a type of Transform" (when tried from VS2012), where xxxxx is the full name of our custom transform class.
Originally we have implemented the custom transform using the https://www.nuget.org/packages/Microsoft.Web.Xdt nuget package which supplied version 1.2.31129.0 of Microsoft.Web.XmlTransform.dll - the same assembly as the one located in "c:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\Web\" as of VS 2012 Update 3.
With WebDeploy 3.5 however, our transformations started to fail and we noticed that a new version of Microsoft.Web.XmlTransform.dll was added to "c:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\Web\", version 1.4.41009.0. As the nuget package has not yet been updated, to work around the issue we recompiled our custom transformation assembly against version 1.4.41009.0, referencing it directly from the aforementioned folder. For this, as the new version of Microsoft.Web.XmlTransform.dll is a .net 4.5 assembly, we retargeted our own custom transformation assembly to .net 4.5 as well.
Despite these efforts, using the new custom transformation assembly did not help and the error messages we got earlier remained.
Not being able to find any information online and not knowing what "Transform" base class the transform task expects I opened up this fresh version of Microsoft.Web.XmlTransform.dll with dotpeek and converted it to a csproj. I took the courage and edited the file where the VS error message is constructed to include the full name of the base type, compiled the assembly and - after backing the original up - used that to overwrite the official, signed Microsoft.Web.XmlTransform.dll in "c:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\Web\".
I have retried the transform/publish operation from VS2012 and to my surprise the transform and the deploy passed!
I am totally confused at this point: our custom transform is still compiled against Microsoft.Web.XmlTransform.dll 1.4.41009.0 (digitally signed by Microsoft 10/10/2013) BUT it only functions if we disassemble and then recompile Microsoft.Web.XmlTransform.dll (to the same version and virtually no changes but obviously without the digital signature) and then hack-copy it into "c:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\Web\", overwriting the original file that came with WebDeploy 3.5.
We have tried this on several developer machines, each one running Windows 7 with the latest patches and Visual Studio 2012 Update 4 with WebDeploy 3.5.
I would appreciate any help in finding a workaround and will extremely appreciate someone pointing out any obvious mistakes I may have made. I will also appreciate a fix from Microsoft in case it is caused by a bug on their side and perhaps links to any relevant bug reporting interfaces where I could post this.
Thank you.