Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Lisp Problems in 2015

5 REPLIES 5
Reply
Message 1 of 6
jeffschueler
2098 Views, 5 Replies

Lisp Problems in 2015

Has anybody else experienced problems with getting their lisp routines to work with 2015?  I've got a bunch of lisp I've written over time (10's of thousands of lines of code ).  We're on AutoCAD MEP 2014, and everything currently works perfectly with it (and previous releases), but 2015 is another story...

 

I'm getting "bad argument type: stringp nil" errors with a bunch of routines.  (those I can probably work through)

 

The most confusing error I'm getting is this:

Cannot invoke (command) from *error* without prior call to (*push-error-using-command*).
Converting (command) calls to (command-s) is recommended.

I have several routines that throw the above error, some of which do not even use an *error* handler.  I only have a couple *error* definitions which use command, and I've tried rewriting them using command-s with the same results in 2015, but same code throws ARX errors in 2014 (which seems strange to me since supposedly command-s has been available since 2012?)  Using *push-error-using-command* also returns the same results.

 

Several error definitions call print, alert, or princ, all of which I thought were allowable in *error* definitions?  Are there other lisp functions not allowed in *error* that are throwing the above error?  (again, all this stuff has worked for years in previous releases...)

 

I suspect it has something to do with this:

http://through-the-interface.typepad.com/through_the_interface/2014/03/autocad-2015-calling-commands...

But, I'm not really sure what to make of it.

 

If anyone can give me any pointers or even send me in the right direction, it would me much apreciated.  Thanks.

 

5 REPLIES 5
Message 2 of 6
_gile
in reply to: jeffschueler

Hi,

 

I noticed that, with A2015, you have to use command-s instead of command within the functions called by higher order functions (i.e. a lambda function passed as argument to mapcar).

for more informations about the command-s function, you can have a look here:

http://docs.autodesk.com/ACDMAC/2014/ENU/index.html?url=files/GUID-5C9DC003-3DD2-4770-95E7-7E19A4EE1...

 



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Message 3 of 6
jeffschueler
in reply to: _gile

Thanks, I'll keep that in mind as I'm going through my code base bringing it up to compatibility with 2015.

 

In the meantime, I've done some more testing loading only a simple error handler lisp into a clean install of 2015, and the error handler with command-s does work as expected.  I have a large codebase I support, so it seems I still have at least one stray error function using command somewhere (or possibly other existing functions that use command).

 

Reguardless though, command-s does not work for me with 2014 or 2013 products I've tested (vanilla acad and acad MEP).  Looks like I now have to implement version checking for all error handlers and any other places command-s is required in place of command.  (I guess I'd have to do this anyways because I support code for offices using versions of acad older than 2012).

 

Message 4 of 6
Simon_Weel
in reply to: jeffschueler

 
Message 5 of 6
Simon_Weel
in reply to: jeffschueler

Same problem here. I thought Autodesk had stopped VLisp development for a long time. Can't check it for release 2011/12, but 'command-s' isn't available in AutoCAD 2010. It is in 2013 and newer. Can't find anything about What's New in VLisp, so I wonder what else has changed. Definitely not the weird looking toolbar colors in the IDE. Simon
Message 6 of 6
Simon_Weel
in reply to: Simon_Weel

OK, so it's in the Help text. There's a page listing changes for every version. Command-s was added in release 2012. Doesn't explain why 2015 starts nagging about this? Simon

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

Post to forums  

Autodesk Design & Make Report

”Boost