Questions tagged [managed]

Managed refers to code that requires and will only execute under the control of a Common Language Runtime (CLR). Any code written in C# or Visual Basic .NET is managed code.

890 questions
7
votes
2 answers

How do I combine an unmanaged dll and a managed assembly into one file?

SQLite from PHX Software has combined a managed assembly (System.Data.SQLite) with an unmanaged dll (the SQLite 32- or 64-bit dll) into one file, and managed to link them together. How do I do this? Do I need to embed the managed assembly into the…
Lasse V. Karlsen
  • 380,855
  • 102
  • 628
  • 825
7
votes
2 answers

MSBuild Managed vs Unmanaged property

Is there a way in MSBuild logic to determine if I am running managed vs unmanaged code? Not C++ vs C#, but just managed vs unmanaged? I'd like to set some properties (usually just version information) differently depending on whether the code is…
Eric Kulcyk
  • 279
  • 3
  • 15
7
votes
2 answers

How can I declare constant strings for use in both an unmanaged C++ dll and in a C# application?

Curently I'm passing my const string values up from my C++ into my C# at startup via a callback, but I'm wondering if there's a way of defining them in a C++ header file that I can then also refer to in C#. I already do this with enums as they are…
Surfbutler
  • 1,529
  • 2
  • 17
  • 38
6
votes
3 answers

Finding memory leaks in a managed Win8 metro app?

I'm currently working on a metro game for Windows 8 using C# and SharpDX. The project is going well, but recently there's been a need to start tracking down memory leaks and I'm not really sure where to begin. The built in memory profiler in Visual…
Ben Smith
  • 143
  • 2
  • 7
6
votes
2 answers

HOWTO: Call Managed C# Interface From Unmanaged C++ On WindowsCE Compact Framework

I have extensive unmanaged Windows CE 5 C++ code that provides a UI that I want to use in a new product by combining it with a large amount of newer business and communications logic written in managed C# on Windows CE 6 and the Compact…
James Barnard
  • 266
  • 2
  • 5
6
votes
2 answers

I get LNK2028 when trying to wrap native c++ class using managed c++

trying to wrap a native cpp class using managed c++ class. all looks good but for some reason it wont compile. getting the following linker errors: Error 25 error LNK2028: unresolved token (0A0002CE) Error 27 error LNK2019: unresolved…
ofer
  • 4,366
  • 9
  • 38
  • 39
6
votes
2 answers

What are managed types? Are they specific to Delphi? Are they specific to Windows?

Summarization: Please check the knowledgeable comments below. ============================================================== I have seen the term of managed types mentioned in quite a few stackoverflow Delphi topics. For example, it is mentioned in…
SOUser
  • 3,802
  • 5
  • 33
  • 63
6
votes
0 answers

How can I modify HTTP headers in ASP.NET (Web Forms) that are defined in web.config

I have some custom HTTP response headers defined in an ASP.NET (Web Forms) website's web.config. I'm trying to write a managed HTTP module that can modify these web.config defined headers before they're sent back to the client. Unfortunately,…
6
votes
3 answers

Managed version of Spy++ Tool?

Awhile ago, I needed a Spy++ like application for some .NET UI debugging. I found an old MSDN article with a sample that does things similarly, But that stopped working in newer .NET Framework versions. Does anyone know of/wrote an application that…
Ran Sagy
  • 610
  • 7
  • 17
6
votes
1 answer

managed code vs unmanaged code

I'm trying to get my mind wrapped around the concept of managed vs unmanaged code. Correct me if I'm wrong but managed code is anything that gets compiled down to bytecode while unmanaged code gets compiled down to machine code. Is this correct?
conterio
  • 1,087
  • 2
  • 12
  • 25
6
votes
1 answer

"C# base class virtual function" - "override in Managed C++ ref class"

I have a .NET_4 Managed C++ ref class that I derive from a .NET_4 base class written in C#. C# base class: namespace Core { public class ResourceManager { public class _Resource { public virtual void Delete() {} } …
zezba9000
  • 3,247
  • 1
  • 29
  • 51
6
votes
4 answers

What happened to ManagedSpy?

ManagedSpy is supposed to be the .NET equivalent of Spy++, but somehow the download page is now not availeble any more. Anyone who knows why? Anyone that knows a replacement? --jeroen
Jeroen Wiert Pluimers
  • 23,965
  • 9
  • 74
  • 154
6
votes
1 answer

In Managed C++, what is the proper way to define a static singleton instance in a class?

Jumping to Visual Studio 2015 from Visual Studio 2013, I've noticed some differences in how static self-instances in managed C++ classes are accepted by the compiler. Consider these two examples: Method 1: public ref class…
void.pointer
  • 24,859
  • 31
  • 132
  • 243
6
votes
2 answers

Using unmanaged code from managed code

I have my project developed in MFC which is unmnaged code. Now i need to create a similar application in C#, by reusing most of the MFC classes. Is it possible to directly export class/struct/enum from MFC dll, so that i can import it in my C# using…
Harsha
  • 183
  • 2
  • 8
6
votes
2 answers

How do I find the source of a "A procedure imported by 'xxx.dll' could not be loaded." exception?

I have been chasing this exception for the past week. Situation is: I have an application that is written in C# and built in Visual Studio 2010. The application includes a DLL that is a wrapper of an unmanaged code library. The unmanaged code is…
user1542042
  • 195
  • 1
  • 9