autocad 2010 + VS2010 32b - autocad can't see the breakpoint in VS

autocad 2010 + VS2010 32b - autocad can't see the breakpoint in VS

Anonymous
Not applicable
1,566 Views
6 Replies
Message 1 of 7

autocad 2010 + VS2010 32b - autocad can't see the breakpoint in VS

Anonymous
Not applicable

Hello i want use VS2010 for debugging but VS dont stop where is my breakpoint.

 

I have following the tuto for the hello word  example for autodesk. tutorial.

 

I have try so many solution but all dont work...

 

Help please..

 

 

 

 

0 Likes
Accepted solutions (1)
1,567 Views
6 Replies
Replies (6)
Message 2 of 7

StormyC
Advocate
Advocate
Accepted solution

The below proceedure works for me (VS210 32bit, ACAD2010 on WinXP)

 

Find this line in ProjName.VBPROJ ...<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">

And add the following below it.
<StartAction>Program</StartAction>
<StartProgram>C:\Program Files\Autodesk\AutoCAD 2011\acad.exe</StartProgram>

 

ADD LINES BELOW JUST BEFORE </configuration> IN THE ACAD.EXE.CONFIG FILE FOUND IN THE AUTOCAD INSTALL FOLDER
<startup>
  <supportedRuntime version="v2.0.50727" />
</startup>

 

START VS2010
LOAD PROJECT TO BE DEBUGGED
START DEBUGGING
AFTER AUTOCAD HAS STARTED
TYPE "NETLOAD"
SELECT DEBUG CODE .DLL OF PROJECT
SET BRAKE POINTS
EXECUTE COMMAND THAT STARTS THE CODE

 

You must make sure your program is compiled targeting .NET 3.5..

 

Hope this sorts your problem out.

Message 3 of 7

Anonymous
Not applicable

ind this line in ProjName.VBPROJ ...<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">

 

--> i dont have that line..

 

I have :

Application.designer.vb

AssemblyInfo.vb

Resources.Designer.vb

Setting.Designer.vb

 

0 Likes
Message 4 of 7

StormyC
Advocate
Advocate

You can find the file 'YourProjectName.vbproj' in the folder you save your projects to for example.....

 

C:\Documents and Settings\USERNAME\My Documents\Visual Studio 2010\Projects\ProjectName\ProjectName

 

Just do a search for *.vbproj and your should find the one your looking for.

0 Likes
Message 5 of 7

Anonymous
Not applicable

Tank You it work fine !!

 

 

..

 

0 Likes
Message 6 of 7

Anonymous
Not applicable

This post on the "Through the Interface" blog explains the issue and possible 3 solutions in some detail:

 

http://through-the-interface.typepad.com/through_the_interface/2010/04/hitting-breakpoints-in-net-cl... 

0 Likes
Message 7 of 7

Anonymous
Not applicable

Yes i read it before create this post but :

Solution 1

Start the exe that loads your AddIn (acad.exe, revit.exe, etc) and then attach to it from Visual Studio (Debug -> Attach to Process...)

--> I can'f fount it.

 

Solution 2

Modify the config file of the exe that loads your AddIn (acad.exe.config, revit.exe.config, etc) so that it contains the following just before the </configuration> part:

<startup/>

<supportedRuntimeversion="v2.0.50727"/>

</startup>

 

 

>--> I have do this but not working (before your add on the proj.)


Solution 3

Add the exe that loads your AddIn as an existing project to your solution and set the debugger version for it to v2.0.

  1. Right-click the Solution in the Solution Explorer and select Add -> Existing Project... and locate the exe that loads your AddIn

--> i can't fount it ( Add--> Existing project).

I have add new form etc.. but not existing project

 

0 Likes