Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net Web Services (http://www.velocityreviews.com/forums/f64-asp-net-web-services.html)
-   -   Using classes from a C++/CLI dll inside a WCF service - beginner (http://www.velocityreviews.com/forums/t787772-using-classes-from-a-c-cli-dll-inside-a-wcf-service-beginner.html)

Hedley 12-20-2008 06:19 PM

Using classes from a C++/CLI dll inside a WCF service - beginner
 
We are planning to move to an SOA using WCF. We have many 32 bit legacy code
dlls (C++) that we plan to wrap with C++/CLI. The WCF services will then
reference those C++/CLI libraries for functionality that will be exposed
through the services. We are using VS2008 SP1 with .NET3.5 SP1 on Vista 64.

I have successfully wrapped some of the legacy dlls at this point. However
when I try and call the CLI code from methods in a test service, the WCF Test
client immediately fails: "Failed to invoke the service. Possible causes: The
service is offline or inaccessible; the client-side configuration does not
match the proxy; the existing proxy is invalid. Refer to the stack trace for
more detail. You can try to recover by starting a new proxy, restoring to
default configuration, or refreshing the service..."

So, I'm obviously missing something.

This is easily reproduceable:
-create a Visual C++ CLR Library
-Create a simple class called Class1 in the CLR library
-Create a WCF Service Library, reference the CLR Library
-In the wizard created GetDataUsingDataContract() method, add Class1 c = new
Class();
-start the service and get the error from the test client.

Can someone straighten me out?

Thanks!


--------------------------------------------------------------------------------

HedleySohn

Ram245 11-08-2013 11:51 AM

Hello Hedley

Do you find anything...??? useful
Im trying the same way. can you please help me out.
Can you please share some samples

Regards
Ramakrishnan

Quote:

Originally Posted by Hedley (Post 4326484)
We are planning to move to an SOA using WCF. We have many 32 bit legacy code
dlls (C++) that we plan to wrap with C++/CLI. The WCF services will then
reference those C++/CLI libraries for functionality that will be exposed
through the services. We are using VS2008 SP1 with .NET3.5 SP1 on Vista 64.

I have successfully wrapped some of the legacy dlls at this point. However
when I try and call the CLI code from methods in a test service, the WCF Test
client immediately fails: "Failed to invoke the service. Possible causes: The
service is offline or inaccessible; the client-side configuration does not
match the proxy; the existing proxy is invalid. Refer to the stack trace for
more detail. You can try to recover by starting a new proxy, restoring to
default configuration, or refreshing the service..."

So, I'm obviously missing something.

This is easily reproduceable:
-create a Visual C++ CLR Library
-Create a simple class called Class1 in the CLR library
-Create a WCF Service Library, reference the CLR Library
-In the wizard created GetDataUsingDataContract() method, add Class1 c = new
Class();
-start the service and get the error from the test client.

Can someone straighten me out?

Thanks!


--------------------------------------------------------------------------------

HedleySohn



All times are GMT. The time now is 02:24 AM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.