0 Members and 1 Guest are viewing this topic.
Why not just use vla-plottofile?
Quote from: Lee Mac on January 13, 2010, 11:45:39 AMWhy not just use vla-plottofile?sorry i don't know how to use the function of "vla-plottofile",can you give me some Example!
Quote from: aicr317 on January 13, 2010, 12:41:24 PMQuote from: Lee Mac on January 13, 2010, 11:45:39 AMWhy not just use vla-plottofile?sorry i don't know how to use the function of "vla-plottofile",can you give me some Example!Provided in #9
Quote from: Lee Mac on January 13, 2010, 12:41:58 PMQuote from: aicr317 on January 13, 2010, 12:41:24 PMQuote from: Lee Mac on January 13, 2010, 11:45:39 AMWhy not just use vla-plottofile?sorry i don't know how to use the function of "vla-plottofile",can you give me some Example!Provided in #9 I TRIED IT , PROBLEM:HOW TO SET/CONTROL THE "WINDOW OF PLOT AREA" AND "PAPER SIZE" ....AS SO ON ,SUCH AS "PLOT STYLE TABLE"......
Quote from: aicr317 on January 13, 2010, 12:51:21 PMQuote from: Lee Mac on January 13, 2010, 12:41:58 PMQuote from: aicr317 on January 13, 2010, 12:41:24 PMQuote from: Lee Mac on January 13, 2010, 11:45:39 AMWhy not just use vla-plottofile?sorry i don't know how to use the function of "vla-plottofile",can you give me some Example!Provided in #9 I TRIED IT , PROBLEM:HOW TO SET/CONTROL THE "WINDOW OF PLOT AREA" AND "PAPER SIZE" ....AS SO ON ,SUCH AS "PLOT STYLE TABLE"......It is all set in the PlotConfiguration object - if a PC3 file is not provided to my example, it will use the current plot configuration.
(defun c:P2F (/ doc itemp SetPS PlottoFile pgset file) ;; Lee Mac ~ 13.01.10 (vl-load-com) (defun doc nil (setq *doc* (cond (*doc*) ((vla-get-ActiveDocument (vlax-get-acad-object)))))) (defun itemp (collection item / result) (if (not (vl-catch-all-error-p (setq result (vl-catch-all-apply (function vla-item) (list collection item))))) result)) (defun SetPS (lay setup) (and (setq lay (itemp (vla-get-layouts (doc)) lay)) (setq setup (itemp (vla-get-PlotConfigurations (doc)) setup)) (not (vla-copyfrom lay setup)))) (defun PlottoFile (file pc3 cpy) (setq plt (vla-get-plot (doc))) (and cpy (eq 'INT (type cpy)) (vla-put-NumberofCopies plt cpy)) (eq :vlax-true (vla-plottofile plt file pc3))) ;; ---------------------------------------------------- (if (and (setq pgset (getstring t "\nSpecify Page Setup to Use: ")) (SetPS (getvar 'CTAB) pgset)) (if (setq file (getfiled "Output File" "" "plt" 1)) (PlottoFile file nil 1)) (princ "\n** Page Setup Not Found **")) (princ))
THANK YOU ,IF YOU GOT THE RESULT OF MY POST IN #5 ,PLEASE TELL ME !