Bill Tillman Posted March 6, 2015 Share Posted March 6, 2015 Okay, here's the deal. I was running a machine yesterday which had AutoCAD 2013. I was also using a C# program in Visual Studio Express which gathered some data, launched AutoCAD 2013, loaded and executed a LISP file which prepared and saved a drawing. Everything worked fine. Last night they updated my system to a new, faster machine which has AutoCAD 2015 Mechanical. I'm using the same Visual Studio C# code and the same LISP code. The process starts, AutoCAD opens and starts the drawing but then it pauses. I can see where it pauses and I checked the LISP code for any anomalies but nothing seems to be there. So I loaded the LISP code on the 2015 machine with the LISP IDE opened and ran it from the AutoCAD command line and it worked fine. This thing only pauses when I'm running it from the C# code using AutoCAD 2015. The pause which happens can be continued if I focus Windows on the AutoCAD window and click the mouse or press enter. But this only happens on the 2015 machine. This pause does not happen on the 2013 machine, using the exact same code. And yes, I swapped out the 2015 COM reference in VS for the 2013 COM reference when I switch between machines. I know exactly where the code is pausing and it's between two dimlinear commands: (command "._DIMLINEAR" (polar (polar pt1 pi 4) a90 2) (polar (polar pt2 0 4) a90 2) (polar pt1 a90 24) "") (command "._DIMLINEAR" (polar (polar pt1 pi 2) a90 4) (polar (polar pt4 pi 2) a270 4) (polar pt1 pi 24) "") The first dimlinear command executes and then that's where it pauses in 2015. The second command does not execute unless I interact with it. And as most of you know, I'm working on strictly automated programs which cannot depend on any user input, of any kind. Quote Link to comment Share on other sites More sharing options...
Tharwat Posted March 6, 2015 Share Posted March 6, 2015 Hi , Replace the command call name 'command' with 'command-s' when you switch to cad 2015 and try again . Quote Link to comment Share on other sites More sharing options...
Bill Tillman Posted March 6, 2015 Author Share Posted March 6, 2015 Thanks. That took care of that command....but it paused right again after that. Is this "-s" something unique to AutoCAD 2015, or Mechanical.... and if so, should I change all the "command" to "command-s"? That's no problem but at least some of the command without the -s is working. Quote Link to comment Share on other sites More sharing options...
BlackBox Posted March 7, 2015 Share Posted March 7, 2015 http://through-the-interface.typepad.com/through_the_interface/2014/03/autocad-2015-calling-commands.html Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.