Search the Community
Showing results for tags 'vba plot'.
Found 1 result
Hey everyone. I am working on a vba plot tool that I am having a few issues with. I was having trouble setting the paper size and after a ton of searching I found the "blad" section of coding which seems to be working with the exception of the sheet style. Maybe it should be plotstyle? My other main issue is that when I run this module, it takes 30 seconds or so before it prints. What is causing the delay? I have no loops or arrays, so I'm not sure why its taking so long. Public Sub Plot_11x17() Dim PntrName As String Dim CTBhalf As String Dim blad As AcadLayout PntrName = UserForm1.PntrName.Value CTBhalf = UserForm1.CTBhalf.Value 'Set Values Set blad = ThisDrawing.Layouts.Item(layout1) ThisDrawing.ActiveLayout = blad blad.ConfigName = PntrName blad.CanonicalMediaName = "11x17" blad.PlotType = acExtents blad.CenterPlot = True blad.StandardScale = acScaleToFit blad.ScaleLineweights = False blad.StyleSheet = CTBhalf '<<<<<<<<<<<<<<<<<<< not working!!!!!!!!!! blad.PlotWithPlotStyles = False blad.PlotWithLineweights = fasle 'Set Number of Copies ThisDrawing.Plot.NumberOfCopies = 1 'Initiate Plot ThisDrawing.Plot.PlotToDevice End Sub