Comments on: Deploying MATLAB Functions as .NET Web Services https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/?s_tid=feedtopost Loren Shure is interested in the design of the MATLAB language. She is an application engineer and writes here about MATLAB programming and related topics. Fri, 18 Nov 2011 14:06:04 +0000 hourly 1 https://wordpress.org/?v=6.2.2 By: Peter Webb https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/#comment-32692 Fri, 18 Nov 2011 14:06:04 +0000 https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/#comment-32692 ML,

It sounds like IIS can’t find the MCR. Probably that means that IIS needs to have /runtime/ on its path, since that’s where the versioned MCLMCRRT DLL is stored. In some circumstances, you many need to put /bin/ on the path as well. ( is short for “architecture” and in your case is either win32 or win64, depending on the bit-width of your MATLAB installation.)

]]>
By: ML https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/#comment-32570 Thu, 27 Oct 2011 19:26:29 +0000 https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/#comment-32570 –by the way , I have installed the MCRInstaller 7.14 on both my machine and the web server.

]]>
By: ML https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/#comment-32569 Thu, 27 Oct 2011 19:24:36 +0000 https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/#comment-32569 I have a MATLab .dll built on 32bit version of Matlab targeting .net 2.0 framework. I am creating a VS 2010 WCF Web Service and referencing this .dll. The web service is .net 4.0 Framework.

MATLAB Version 7.11.0.584 (R2010b)

I have enabled 32 bit applications for the application pool in IIS 7.0

It works fine in my cassini browser in VS Studio 2010. But when I try to run from Web Server using IIS 7.0, I get the following errors:

[FaultException: Server was unable to process request. —> The type initializer for ‘Proj.Class1’ threw an exception. —> The type initializer for ‘MathWorks.MATLAB.NET.Utility.MWMCR’ threw an exception. —> The type initializer for ‘MathWorks.MATLAB.NET.Arrays.MWArray’ threw an exception. —> Unable to load DLL ‘mclmcrrt7_14.dll’: The specified module could not be found.

any ideas?

]]>
By: PMCS https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/#comment-32429 Fri, 19 Aug 2011 15:02:15 +0000 https://blogs.mathworks.com/loren/2011/08/17/builder-ne-and-the-windows-communication-foundation/#comment-32429 A short addendum to the information provided in the post:

When you’re building the Snowflake project using MATLAB’s deploytool, make sure that you’re building for the correct version of the .NET framework (this can be specified in the deploytool Settings dialog).

I initially tried to build the solution under VS2010 without paying attention to this and got errors because deploytool defaults to targeting the .NET framework 2.0. VS2010 wanted to build with .NET framework 3.5, and I ended up getting build errors.

]]>