calling managed c# component from unmanaged c++ code, how do i define config


calling managed c# component from unmanaged c++ code, how do i define config



I want to call a C# component from an unmanaged c++ service. I need to set config items expected by the C# component. What name should be config be and where should it be located.

eg. parentfolder\cplusplusservice.exe

anotherfolder\csharp.dll

i need csharp.dll.config or its equivalent.

Thanks,




Developing Math libraries

1:



Is this a good practice? “/*/something/*/something//*/”
The .config file needs to be named the same as the application's name.


Windows Setup Project without .net dependency
When the unmanaged code first calls into the managed code an AppDomain is created that AppDomain controls which config file is loaded and from where..
Crash when using C# Assembly from Managed C++ DLL
You will need to manually copy the .config file to the output directory and name it after the application name or create a post-build to do so.


Not receiving callbacks from the Java Access Bridge
.
Compiler for Windows Mobile OS
Basically the same rules that apply to where .config files need to be for pure managed apps apply to unmanaged apps that load managed code..
Grab entire document tree with OpenOffice API


Microsoft Visual C++ 2003, 2005— Are They .Net or Unmanaged?

2:


This article shows how to use Configuration files with c#:. http://www.devasp.net/net/articles/display/679.html. This article provides an overview of calling managed c# component from unmanaged c++ and vice versa, as well as some helper classes:. http://www.codeproject.com/KB/mcpp/unmanaged_to_managed.aspx.


3:


It depends on how the AppDomain that is hosting your managed code is created.. For example, if you are exposing the managed code as COM, it will be loaded into the default AppDomain, and the configuration file will be in the same directory as the executable (parentfolder\cplusplusservice.exe.config in your case).. If you are creating the AppDomain yourself, you can control where the configuration file is located..



88 out of 100 based on 48 user ratings 1198 reviews