locked
"Error while trying to run the project: Unable to start debugging" ; VS2008 RRS feed

  • Question

  • I am a very small C# BHO (IE Add-on program) that I can't debug with IE using VS2008. First, for the Debug properties, I specify:
        C:\Program Files\Internet Explorer\iexplore.exe

    But get the message "Error while trying to run the project: Unable to start debugging". No details, no error codes, no explanation!! I tried on a different machine with the same results. Even tried on a W7 machine with the exact same results.

    Next, I tried specifying Debug->Start external program C:\Program Files\Internet Explorer\iexplore.exe on a very simple test project, and still VS2008 does not seem to be able to launch IE - same error message.  It seems VS2008 can't launch IE.  This is very frustrating. 

    I checked an older version of the program under VS2005 and it does launch IE just fine - so what is the problem???

    VS2008/SP1, XP, W7


    warren
    Friday, July 2, 2010 5:57 PM

Answers

  • Hi Warren: 

    Any chance this has to do with UAC? 

    If UAC is enabled only a process run as an admin can spawn another process.   Are you running Visual Studio as administrator?

    Wendell

    Tuesday, July 20, 2010 6:05 PM

All replies

  •  

    Hi,

    I create a simply console application and specify "C:\Program Files\Internet Explorer\iexplore.exe" as parameter of 'Start external program' option, when I press F5 to start debugging, the IE window shows. so you may also create a console application and try again.

     

    However, as a workaround, you may start IE manually, and attach VS to the IE process to debug your BHO add-on.


    Sincerely,
    Eric
    MSDN Subscriber Support in Forum
    If you have any feedback of our support, please contact msdnmg@microsoft.com.
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    • Proposed as answer by Diaz Loya Saturday, October 13, 2012 7:24 PM
    Monday, July 5, 2010 6:32 AM
  • Eric,

    Thank you for your reply!

    I tried creating a simple C# Console app specifying IE as the 'Start external program' option and still get same error message.  Something is wrong with my system, but how can I find what that is???  Also, why the same problem on a brand new W7 machine as well? The error message should be more descriptive.

    Using Debug -> Attach to Process (IE) does not work for me either. It attaches fine, but the breakpoints are not active. When I mouse over the red breakpoint system I get "The breakpoint will be currently be hit. No symbols have been loaded for this document."  The project was compiled in Debug mode. How do you load the symbols?

    Warren

     

    Note: I have reapplied SP1 to VS2008 but no difference.


    warren
    Tuesday, July 6, 2010 5:33 PM
  •  

    What if you specify another program for the 'Start external program' option? for example, use "C:\Windows\system32\notepad.exe" and see whether VS can start notepad.

     

    After attached to IE process, in VS IDE, select Debug menu -> Windows -> Modules to open Modules window, look for your add-on module, right click the item and select "Symbol Load Information...", you can see some directories that VS has looked for the symbol file, make sure you have a corresponding .pdb file in any of those directories.


    Sincerely,
    Eric
    MSDN Subscriber Support in Forum
    If you have any feedback of our support, please contact msdnmg@microsoft.com.
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    Wednesday, July 7, 2010 3:23 AM
  • Eric,

    1. I was able to launch notepad successfully as you described.  When I opened the Attach to Process dialog, I do see iexplore.exe with the title "Error while trying to run the project: Unable to start debugging" ; VS2008 - Windows Internet Explorer.

    2. After I attached to the IE process, from VS2008 there is NO Debug->Windows->Modules option. It does not exist. From Debug->Windows the only choices are: Breakpoints, Watch, Locals, Call Stack, Threads.

     


    warren
    Monday, July 12, 2010 9:54 PM
  • Hi Warren: 

    Any chance this has to do with UAC? 

    If UAC is enabled only a process run as an admin can spawn another process.   Are you running Visual Studio as administrator?

    Wendell

    Tuesday, July 20, 2010 6:05 PM