Arin9916 Posted June 6, 2011 Posted June 6, 2011 hi ^^ i wondering how can i open the file(read-only) using lisp. can it possible? Quote
Tharwat Posted June 6, 2011 Posted June 6, 2011 Yes it is possible . Write the File Path of your desired drawing instead of the one that I attached . (vl-load-com) (defun c:Test nil (vla-open (vla-get-documents (vlax-get-acad-object)) [b]"C:\\Users\\TOUCHMATE\\Desktop\\My Drawing.dwg"[/b] :vlax-true ) ) Tharwat Quote
Tharwat Posted June 6, 2011 Posted June 6, 2011 wow...you great!!! thanks ^^ You're welcome Arin Tharwat Quote
Arin9916 Posted June 6, 2011 Author Posted June 6, 2011 I USE THIS SOURCE THAT SCRIPT. FOR EXAMPLE " (vla-open (vla-get-documents (vlax-get-acad-object)) "C:\\a.dwg" :vlax-true ) CIRCLE 0,0 100,100 CLOSE (vla-open (vla-get-documents (vlax-get-acad-object)) "C:\\B.dwg" :vlax-true ) CIRCLE . . . BUT IT DO NOT WORK T_T I want make plot lisp using script and lisp but if file already open , script error.. so i want file open(readonly) then plot and close without save. lisp is so hard T T Quote
Tharwat Posted June 6, 2011 Posted June 6, 2011 You are using Lisp for such a useless things , why do not you open the file normally and after that run your scripts without including the vl codes in that script file . And why you are blaming codes since your script file rejecting the status of read only drawing ? 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.