Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 08/21/2021 in all areas

  1. Like lee why ? If you want a lets look use a lisp open a file and read each line then can release file name. (setq Path "yourfile") (setq fo (open path "R")) (while (setq str (read-line fo)) (princ str) (princ "\n") ) (close fo) Mhupp forgot to hit submit button yesterday same idea.
    1 point
  2. Thanks Lee, behind the scenes this was provided to Manuel. https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/publish-dsd-file/td-p/1350729 Needs to merge the 2. (defun c:makedsd (/ file layouts_to_plot NumTabs OldFda ) (setq OldFda (getvar "FILEDIA")) (setvar "FILEDIA" 0) ;;;(setq layouts_to_plot (dos_multilist "Create Multi-sheet DWF file" "Select drawings" (layoutlist))) (setq NumTabs (length layouts_to_plot));Number of tabs selected (setq pathtxt (strcat (getvar "dwgprefix") "newfile.dsd")) (setq file (open (strcat (getvar "dwgprefix") "newfile.dsd") "w")) (write-line "[DWF6Version]" file) (write-line "Ver=1" file) (write-line "[DWF6MinorVersion]" file) (write-line "MinorVer=1" file) (write-line (strcat "[DWF6Sheet:"(substr (getvar "dwgname") 1 (- (strlen (getvar "dwgname")) 4))"-" (getvar "ctab") "]")file) (write-line (strcat "DWG=" (getvar "dwgprefix")(substr (getvar "dwgname") 1 (- (strlen (getvar "dwgname")) 4)) ".dwg")file) (write-line (strcat "Layout=" (getvar "ctab") )file) (write-line (strcat "Setup=" )file) (write-line (strcat "OriginalSheetPath=" (strcat(getvar "dwgprefix")(substr (getvar "dwgname") 1 (- (strlen (getvar "dwgname")) 4))".dwg") )file) (write-line (strcat "Has Plot Port=1" )file) (write-line (strcat "[Target]") file) (write-line (strcat "Type=1" ) file) (write-line (strcat "DWF=" (strcat(getvar "dwgprefix")(substr (getvar "dwgname") 1 (- (strlen (getvar "dwgname")) 4))".dwf") )file) (write-line (strcat "OUT="(strcat(getvar "dwgprefix") )) file) (write-line (strcat "PWD=" )file) (close file) (command "_.delay" 2000) (command "-Publish" pathtxt ) (setvar "FILEDIA" OldFda) (startapp "explorer /e," (getvar "dwgprefix")) (princ) );defun
    1 point
×
×
  • Create New...