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

bad argument stringp nil

10 REPLIES 10
Reply
Message 1 of 11
Anonymous
1094 Views, 10 Replies

bad argument stringp nil

Hello,

 

I have a custom lisp routine LAYMOVE.LSP that works in conjunction with a custom screenmenu LDF.MNU (as well as ldf.mnr, ldf.mnc, ldf.mns)

 

The routine is working fine on two of three workstations.  The intention of routine is to move selected drawing entities from one or more single-node layers to a three-node layer system.   (i.e.  item selected on layer, i.e.,  "arwall" can be moved to layer "1st-flr-arwall").

 

The error  "bad argument: stringp nil" is received.  I try performing same exact function on other stations in same drawing using ACA2014 and no error received.

 

Is it possible that there is a setting or configuration on problem pc that is different from others?

 

thank you,

 

Edward

 

file attached

 

 

 

 

 

 

10 REPLIES 10
Message 2 of 11
hmsilva
in reply to: Anonymous

Welcome to the Autodesk Community, Edward

 

At the workstation where the code is giving error, try this:

in vlisp editor (VLIDE), menu debug and break on error,

then load your code, run the code and when an error occurs,

go to menu debug and last break source, to see what is causing the error, and the error should be highlighted...

 

The "bad argument: stringp nil" error, means that a function is waiting for a string argument, and received a nil as argument.


HTH
Henrique

EESignature

Message 3 of 11
Lee_Mac
in reply to: Anonymous

Further to Henrique's suggestion, here is a tutorial explaining the debugging process to help you locate the error.

 

Lee

Message 4 of 11
Anonymous
in reply to: Lee_Mac

I tried steps but must be missing something... any chance the instructions can be itemized (bullet listed?)

 

thanks kindly,

 

ET

 

Message 5 of 11
Anonymous
in reply to: Anonymous

also, any chance anyone d-loaded the lsp file and tried it....?

 

ET

Message 6 of 11
Anonymous
in reply to: Anonymous

another point to add..

 

The routine works on two other workstations with same cad software and version.

Is there some possible setting variable I am missing?

Message 7 of 11
Lee_Mac
in reply to: Anonymous


@Anonymous wrote:

I tried steps but must be missing something... any chance the instructions can be itemized (bullet listed?)


Where do you get stuck when following my tutorial?

Message 8 of 11
Anonymous
in reply to: Lee_Mac

I found solution to my "error: bad argument stringp nil" :

 

 

I have the lisp routine on a network server (that is in trusted file location) but tried adding a options>file support path>    pointing to that same directory and voila, the lisp routine then finds the LDF.MNU  file it is seeking for list of choices and routine works as should be.   The lisp code is fine, and ultimately just a network path issue.

 

thanks to all

Message 9 of 11
Anonymous
in reply to: Anonymous

Good deal. Mark the post that was most helpful as your solution, or if none were, your own post 😄

This way people know that the question in the thread has been answered, without having to view the thread's page.

Message 10 of 11
Anonymous
in reply to: Anonymous

@BHULL1985

 

QUESTION:  How does one "mark" the post?  happy to do so...

 

ET

Message 11 of 11
Anonymous
in reply to: Anonymous

If you opened the thread, you should have the option to "Accept as Solution" for each person who has posted in your thread.

The one that was most helpful should get the click.

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

Post to forums  

Autodesk Design & Make Report

”Boost