Problems in debugging a C program under Visual Studio 2010 attached to an external program launching it

2023-04-05T13:06:18.5866667+00:00

I've a program in C launched by another program in Visual Basic 6 and when I try to put a breakpoint in the C code I always get the message: "The breakpoint will not currently be hit. No symbols have been loaded for this document" I've made the debug version of C program under Debug\Win32 and I've copied the file "exe" and "pdb" in the folder of the launching program, in Visual Basic 6 I've attached the C program to the launching program and specify the Select Code Type as "Native code" (default proposal, but I've also tried Managed (v4.0)+Native) I've also accessed to Tools\Options\Debugging\Symbols and set Symbol file (.pdb) location. However all my attempts have been unsuccessful. P.S.: I run Visual Studio 2010 and Visual Basic 6 on Windows 7 64 bits. Thank You very much in advance for Your suggestions Carlo Timossi

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,888 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Anna Xiu-MSFT 27,891 Reputation points Microsoft Vendor
    2023-04-06T06:58:00.41+00:00

    Hi @Timossi, Carlo (Paul Wurth Italia S.p.A.)

    Welcome to Microsoft Q&A! 

    Please go to Tools > Options > Debugging > General > try to uncheck “Enable Just My Code”. 

    By the way, Visual Studio 2010 and Visual Basic are out of support. 

    Update:

    Are you in Debug or Release mode? You can delete obj and bin folders in your project folder and try again.

    Sincerely, Anna


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment". 
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments