topogigio Posted Thursday at 02:17 PM Posted Thursday at 02:17 PM (edited) Hello. I'm new here and i'm a basic hobbist programmer in autolisp. My problem Is this error: Error: wrong (bad) function: < Entity name: ....> This is my test code (simplified) , that would be modified to greater selection (ssget "_x" (list (0 . "*Polyline ) (8 . "1")) and a while loop that calls the function, where there are some if and while cycles ( a lisp that i created and works on a single Entity) (setq selezione (ssget ":s") (setq a (ssname selezione 0) (defun estraz_vertici (elem) (setq param ( entget elem)) (print param) ) (Estraz_vertici (a)) I read that entity name Is a pointer (i have no advaced knowledge in programming) and i don't know how to work with It in this case. Thank you in Advance Edited Thursday at 09:22 PM by SLW210 Added Code Tags!! Quote
SLW210 Posted Thursday at 09:24 PM Posted Thursday at 09:24 PM Please use Code Tags for your Code not Quote Tags. (<> in the editor toolbar) Quote
Steven P Posted Thursday at 09:46 PM Posted Thursday at 09:46 PM In LISP anything enclosed in () is a function (Estraz_vertici (a)) means pass the result of function 'a' to function 'Estraz_vertici' - outside brackets to be a variable I think you want (Estraz_vertici a) 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.