.NET Remoting
조회 수: 10 (최근 30일)
이전 댓글 표시
Using Matlab 2011A, I need to access a remote app that exposes a .NET Remoting inteface.
Here's what I'm doing:
function ConnectRemoteApp()
NET.addAssembly('C:\work\MyCo.Remote.dll');
import MyCo.Remote.*
remoteApp = RemoteUtilities.GetRemoteApp('123.45.67.890');
result = remoteApp.AppName;
Note: Remote.dll contains: (1) implementation of static GetRemoteApp method which returns object implementing IRemoteApp interface (2) declaration of IRemoteApp interface which specifies AppName property
When I execute this function, Matlab says remoteApp has no methods or properties. I know the Remote.dll is good because I can use it from a C# client.
What am I missing?
Thank you.
댓글 수: 4
Kaustubha Govind
2011년 9월 6일
Are you able to use other .NET libraries? For example, from the documentation:
NET.addAssembly('System.Speech')
speak = System.Speech.Synthesis.SpeechSynthesizer;
speak.Volume = 100;
speak.Speak('This is a test')
Pierre
2011년 9월 6일
If you can use other .Net libraries successfully, you might want to check which *.cfg file is being used in a MATLAB context... I'm no more sure about this since I used .Net Remoting quite some time ago, but isn't the connection properties, layers, protocols, contracts, etc. configured according to a config file "next to" the application assembly, so using the same library from a different context (in particular MATLAB instead of a test client application with the correct connection properties) might read property settings from a different source.
답변 (0개)
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!