Jump to content

Search the Community

Showing results for tags 'plottofile'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • CADTutor
    • News, Announcements & FAQ
    • Feedback
  • AutoCAD
    • AutoCAD Beginners' Area
    • AutoCAD 2D Drafting, Object Properties & Interface
    • AutoCAD Drawing Management & Output
    • AutoCAD 3D Modelling & Rendering
    • AutoCAD Vertical Products
    • AutoCAD LT
    • CAD Management
    • AutoCAD Bugs, Error Messages & Quirks
    • AutoCAD General
    • AutoCAD Blogs
  • AutoCAD Customization
    • The CUI, Hatches, Linetypes, Scripts & Macros
    • AutoLISP, Visual LISP & DCL
    • .NET, ObjectARX & VBA
    • Application Beta Testing
    • Application Archive
  • Other Autodesk Products
    • Autodesk 3ds Max
    • Autodesk Revit
    • Autodesk Inventor
    • Autodesk Software General
  • Other CAD Products
    • BricsCAD
    • SketchUp
    • Rhino
    • SolidWorks
    • MicroStation
    • Design Software
    • Catch All
  • Resources
    • Tutorials & Tips'n'Tricks
    • AutoCAD Museum
    • Blocks, Images, Models & Materials
    • Useful Links
  • Community
    • Introduce Yourself
    • Showcase
    • Work In Progress
    • Jobs & Training
    • Chat
    • Competitions

Categories

  • Programs and Scripts
  • 2D AutoCAD Blocks
  • 3D AutoCAD Blocks
  • Images
    • Backgrounds

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Found 1 result

  1. I use vla-PlotToFile to plot dwg to pdf with acWindow plottype, but pdf is offset。 please help,thanks。 (defun c:myplot ( / ) (vl-load-com) (setq adoc (vla-get-activedocument (vlax-get-acad-object))) (setvar "CMDECHO" 0) (setvar "BLIPMODE" 0) (setvar "OSMODE" 0) ;(setvar "LAYOUTREGENCTL" 1) (setq lyout (vla-get-activelayout adoc)) (setq styleSheet "monochrome.ctb") (setq cfgName "AutoCAD PDF (High Quality Print).pc3") (vla-RefreshPlotDeviceInfo lyout) (vla-put-ConfigName lyout CfgName) (vla-put-PaperUnits lyout acMillimeters) (vla-put-plotrotation lyout ac0degrees) (vla-put-PlotType lyout acWindow) (vla-put-CanonicalMediaName lyout "ISO_full_bleed_A3_(420.00_x_297.00_mm)") (vla-put-PlotWithLineweights lyout :vlax-false) (vla-put-PlotWithPlotStyles lyout :vlax-true) (vla-put-StyleSheet lyout styleSheet) (vla-put-CenterPlot lyout :vlax-true) (vla-put-plotrotation lyout ac0degrees) (vla-put-activelayout adoc lyout) (setq ss (ssget "X" '((0 . "INSERT") (2 . "bztk") (67 . 0)))) (setq i -1) (repeat (sslength ss) (setq i (1+ i)) (setq tk_ent (ssname ss i)) (vla-GetBoundingBox (vlax-ename->vla-object tk_ent) 'minpoint 'maxpoint) (setq pointTemp1 (vlax-make-safearray vlax-vbDouble '(0 . 1))) (vlax-safearray-put-element pointTemp1 0 (vlax-safearray-get-element minpoint 0)) (vlax-safearray-put-element pointTemp1 1 (vlax-safearray-get-element minpoint 1)) (setq pointTemp2 (vlax-make-safearray vlax-vbDouble '(0 . 1))) (vlax-safearray-put-element pointTemp2 0 (vlax-safearray-get-element maxpoint 0)) (vlax-safearray-put-element pointTemp2 1 (vlax-safearray-get-element maxpoint 1)) (vla-SetWindowToPlot lyout pointTemp1 pointTemp2) (vla-put-activelayout adoc lyout) (vla-PlotToFile (vla-get-Plot adoc) (strcat (getvar 'dwgprefix) "draw" (itoa i))) ) (setvar "BLIPMODE" 0) (setvar "OSMODE" 231 ) (setvar "CMDECHO" 1) ) test.dwg
×
×
  • Create New...