dxfin
hi can any one help.
i have a lisp file that works in AutoCad , but dosn't in Bricscad
[code](defun c:diein ()
(setq UserOS (getvar "osmode"))
(setq Userdimsize (getvar "dimtxt"))
(setq UserUcsion (getvar "ucsicon"))
(command "_dxfin" "c:/profile/temp/die.dxf")
(setvar "osmode" UserOS)
(setvar "dimtxt" Userdimsize)
(setvar "ucsicon" UserUcsion)
(command "zoom""e""zoom"".85x")
(princ)
)
0
Comments
-
Sorry, but I don't get it:
I understand neither what this script is all about (no need to save and restore variables when reading in a dxf, imo), nor why it shouldn't work (it certainly does so on my linux box, when I adjust the path to point to an existing file).
You would need to be more specific as to what the problem is...0 -
Hi Knutsorry i haven't made this very clear...what is meant to happen is to load a DXF file from a the same folder every time by clicking on a button on a tool bar.we always save a DXF file from CorelDraw to the sample folder all the time. it always has the same name (DIE.dxf)this routine works in AutoCad 20010
(defun c:diein () (setq UserOS (getvar "osmode")) (setq Userdimsize (getvar "dimtxt")) (setq UserUcsion (getvar "ucsicon")) (command "_dxfin" "c:/profile/temp/die.dxf") (setvar "osmode" UserOS) (setvar "dimtxt" Userdimsize) (setvar "ucsicon" UserUcsion)
(command "zoom""e""zoom"".85x")(princ))0 -
Jim, as mentioned by Knut, your code works OK. There must be another issue: DXF format? Path? Diesel?0
-
Hi Royi have managed to drag and drop the dxf file in with out any problems, and i can type DXFIN and locate the file and open it without any problemsi wonder if bricscad has an issue with the path ?Jim.0
-
Try \\ intead of /0
-
Hi Patrikjust changed them to \\ and it works .many thanksJim0
-
Looks like a bug to me... as far as I can remember, the slash should work on all platforms.0
This discussion has been closed.