andy_lee Posted December 2, 2014 Posted December 2, 2014 I have a dll (mytest.dll) with a commandmethod ("cmdtest") I want use lisp load and run. The following code has a problem . if "mytest.dll" is exist, run this code , but still prompt "mytest.dll not loaded!" if if "mytest.dll" is not exist, run this code , prompt "TextToGeom.dll not find!"\nTextToGeom.dll not find!" ??? Repeated prompt (defun c:test () (if (member "mytest.DLL" (mapcar 'strcase (arx))) (command "cmdtest") (if (findfile "mytest.dll") (progn (princ "\nmytest.dll not loaded!") (setvar "cmdecho" 0) (command "netload" (findfile "mytest.dll")) (princ "\nOk, ") (princ (findfile "mytest.dll")) (princ " loaded!") (command "cmdtest") ) (princ "\nmytest.dll not find!") ) ) ) Quote
Tharwat Posted December 2, 2014 Posted December 2, 2014 Regardless if the rest of the routine works or not , but this part that related to member function should be like this . (member "MYTEST.DLL" (mapcar 'strcase (arx))) Quote
andy_lee Posted December 2, 2014 Author Posted December 2, 2014 Regardless if the rest of the routine works or not , but this part that related to member function should be like this . (member "MYTEST.DLL" (mapcar 'strcase (arx))) Thanks, Master Tharwat, Now is ok! add (princ) at end. Quote
Tharwat Posted December 2, 2014 Posted December 2, 2014 Thanks, Master Tharwat, Now is ok! Excellent , Happy to hear that add (princ) at end. That's needed to exit calmly Quote
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.