.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Wrong AutoCAD for Debugging

6 REPLIES 6
SOLVED
Reply
Message 1 of 7
cadcamm99
806 Views, 6 Replies

Wrong AutoCAD for Debugging

I am using AutoCAD Mechanical 2012 and VB 2010 Express.  I am trying to debug my program but it opens up AutoCAD instead of AutoCAD Mechanical.  I am attaching my a copy of my myTable.vbproj.user file.  (I added the .txt to send the file)

 

Does anyone know what else I need in the file?  I did not have this problem when I had AutoCAD Mechanical 2011 and VB 2008 Express.

 

Thanks.

6 REPLIES 6
Message 2 of 7
Alfred.NESWADBA
in reply to: cadcamm99

Hi,

 

>> but it opens up AutoCAD instead of AutoCAD Mechanical

I guess it's not opening another product, it's opening the correct ACAD.EXE, but with the wrong profile/start parameters.

 

Take your icon for Mechanical on your desktop, right-click ==> properties and look to the starting exe + options (all what is defined behind the ...\ACAD.EXE. All behind are start-parameters for AutoCAD to define e.g. the profile, a templatefile, ....

 

Looking now to your .USER file you should modify it that way

    <StartArguments>

        xxxxx

    </StartArguments>


where xxxxx has to be replaced with the parameters as they are defined in the Mechanical starticon properties

 

HTH, - alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at ... blog.hollaus.at ... CDay 2024
------------------------------------------------------------------------------------
(not an Autodesk consultant)
Message 3 of 7
_gile
in reply to: cadcamm99

Hi,

 

I don't know much about Mechanical but I suppose it works like others vertical, AutoCAD (vanilla or vertical) opens according to a profile.

You can specify the profile used to start AutoCAD by:

- adding commandline arguments in the your project property debug tab:

/nologo /p "<profileName>"

 

- or, addin a line to the MSBuild file (vbproj) after the <StartProgram> one:

<StartArguments>/nologo /p "<profileName>"</StartArguments>



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Message 4 of 7
Alfred.NESWADBA
in reply to: _gile

Hi Gilles

 

>> - adding commandline arguments in the your project property debug tab

I think one of the differences between VS2010 (pro) and VB2010Express (which the OP has) is that the Express version does not have a debug-page.

 

>> or, addin a line to the MSBuild file (vbproj) after the <StartProgram> one

I think Gilles meant the VBPROJ.USER file.

 

- alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at ... blog.hollaus.at ... CDay 2024
------------------------------------------------------------------------------------
(not an Autodesk consultant)
Message 5 of 7
_gile
in reply to: Alfred.NESWADBA

Hi Alfred,

 

>> I think one of the differences between VS2010 (pro) and VB2010Express (which the OP has) is that the Express version does not have a debug-page

From my remember VS Express versions (2008 and 2010) had a Debug tab with the commandline arguments box (VS 2012 Express for Desktop do have it). what they missed was the start program box (the reason why it's needed to edit the MSBuild file).

 

>> I think Gilles meant the VBPROJ.USER file.

You're right, but editing the vbproj (or csproj, fsproj) <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> node works too.



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Message 6 of 7
Alfred.NESWADBA
in reply to: _gile

Hi,

 

>> VS 2012 Express for Desktop do have it

Great to know now. I didn't use it, will not use it, but maybe there come a question here and it's good to answer it correctly.

 

>> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> node works too.

To be honest: I have no idea on how to define there the program to start for debug or the startup-parameters.

But as I don't really need it please don't spent time now for describing this. For me it's enough to know "there should be a way). If I have to use it in the future, I will search for it (and if I don't find, I will ask here). 😉

 

thx, - alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
Ingenieur Studio HOLLAUS ... www.hollaus.at ... blog.hollaus.at ... CDay 2024
------------------------------------------------------------------------------------
(not an Autodesk consultant)
Message 7 of 7
cadcamm99
in reply to: _gile

This did the trick.  Weird that I had to put the command on one line.  When I did it like the one above, I kept getting a profile name error. 

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost