How do you return the current drawing name to the command prompt for use in a script file? Does anyone have a lisp that will do this, or is there a simple variable AutoCAD already stores that can be used to get this?
Example
Current drawings name = drawing1.dwg
I want to be able to issue a command via script to return this drawing name, but I want to be able to delete/not include the .dwg extension and type in my own extension as in .txt etc... Is this possible? I also need to type in the save path as in C:/drawing txt files, which the current drawing location may or may not be in that location and have the current drawing (drawing1.txt) be in that location.
C:/drawing txt files/drawing1.txt
I'm trying to learn how to write my own lisp and script files, so I only want as little help with this as possible. I think I have all the other information I need for writing my script file, but I have to have the above mentioned information before I can move on. Thanks to all the gurus in advance.