How to attach debugger to step into native (C++) code from a managed (C#) wrapper? -


i have wrapper around c++ function call call c# code. how attach debugger in visual studio step native c++ code?

this wrapper have calls getdata() defined in c++ file:

    [dllimport("unmanaged.dll", callingconvention=callingconvention.cdecl,                 entrypoint = "getdata", bestfitmapping = false)]         public static extern string getdata(string url); 

the code crashing , want investigate root cause.

thanks, nikhil

check debug tab on project's properties page. there should "enable unmanaged code debugging" checkbox. worked me when developed new .net ui our old c++ dlls.

if unmanaged dll being built project (for while ours being built using vs6) make sure have dll's pdb file handy debugging.

the other approach use c# exe target exe run dll project, can debug dll normally.


Comments

Popular posts from this blog

windows - Why does Vista not allow creation of shortcuts to "Programs" on a NonAdmin account? Not supposed to install apps from NonAdmin account? -

c++ - How do I get a multi line tooltip in MFC -

unit testing - How to mock PreferenceManager in Android? -