I need some help in the following lisp, I changing the CAD Plot log adding extra info that I need like the project number and a Flag and sorting in a different way.
the problem is that if a have many plot cad files the changes are correct, but if I have only ONE file printed no changes occur, I creating a new plot log file avery time I plot,
and I copy that information to another file.
any help will be really appreciated, thank so much.
(SETQ p_Number "9999999")
(SETQ Xcopies "1")
(setq Flag "----")
;; USING THE DOSLIB_9.02 BY R. McNeel
(setq File2Read (dos_readdelimitedfile "C:/Temp/AutoCad-PlotInfo.log")) ;; Xlines 0)
(setq XRow (nth index File2Read))
;; ; ("U:\\100000\\elec\\765471 E-001-00 Ver01.dwg" "42X30" "8/24/2018 9:14:37 AM" "USERNAME" "Oce_TDS750_12th.pc3" "Oce B+ 12x18 in (Landscape)" "1:1.00011" nil)
(setq DrwgName (nth 0 XRow))
(setq TabPrint(nth 1 XRow))
(setq Plot_date (nth 2 XRow))
(setq User_name (nth 3 XRow))
(setq PlotterName (nth 4 XRow))
(setq PaperSize (nth 5 XRow))
(setq datestr (itoa (fix (getvar 'cdate))) ; string in YYYYMMDD format
XMonthstr (substr datestr 5 2) ; month number as string
XYearstr (substr datestr 1 4) ; year
PlotDataFolder "c:/temp/"
)
(setq FileOpen (open (setq filestr (strcat PlotDataFolder XYearstr "-" XMonthstr " " "PlotInfo.log")) ;; |