• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    .NET

    Reply
    Active Contributor
    Posts: 44
    Registered: ‎04-12-2005

    Plot Setting - Window Definition in model space has an offset

    312 Views, 0 Replies
    07-18-2005 12:34 PM
    I have defined a "PlotSetting" that is associated with a "Model Space" layout.

    :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

    oAcadTR = oAcadTM.StartTransaction
    PSPlotSettings = CType(oAcadTR.GetObject(PSObjectID, OpenMode.ForWrite, False, False), PlotSettings)
    Try
    With oPSVal
    .SetPlotConfigurationName(PSPlotSettings, "AutoCAD PostScript File Writer.pc3", MyBase.CananicalPaperSize)
    .RefreshLists(PSPlotSettings)
    .SetDefaultPlotConfig(PSPlotSettings)
    .SetStdScale(PSPlotSettings, 1)
    .SetUseStandardScale(PSPlotSettings, True)
    .SetStdScaleType(PSPlotSettings, StdScaleType.StdScale1To1)
    .SetPlotRotation(PSPlotSettings, PlotRotation.Degrees000)
    Dim oWindow As New Autodesk.AutoCAD.DatabaseServices.Extents2d(myInsPoint.X, myInsPoint.Y, myInsPoint.X + MyBase.FormatWidth, myInsPoint.Y + MyBase.FormatHeight)

    .SetPlotPaperUnits(PSPlotSettings, PlotPaperUnit.Inches)
    .SetPlotWindowArea(PSPlotSettings, oWindow)
    .SetPlotType(PSPlotSettings, Autodesk.AutoCAD.DatabaseServices.PlotType.Window)
    Dim oCusScale As New Autodesk.AutoCAD.DatabaseServices.CustomScale(1.0, 1.0)
    .SetCustomPrintScale(PSPlotSettings, oCusScale)

    .SetPlotCentered(PSPlotSettings, True)
    .SetZoomToPaperOnUpdate(PSPlotSettings, True)
    .SetCanonicalMediaName(PSPlotSettings, MyBase.CananicalPaperSize)
    .SetCurrentStyleSheet(PSPlotSettings, "monochrome.ctb")
    End With
    oAcadTR.Commit()
    Catch ex As Exception
    End Try

    ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

    Here is the problem.

    This works well when plotting in a layout. I get an "Offset" when plotting in model space.

    The resulting Plotsetting window when plotting in Model Space has an offset. I have been unable to determine the source of the offset. I have been testing in an environment where there is only one UCS (world).

    When I modify the PlotSetting manually, the .Net plotsetting (via debugger) object returns window values that have a "negative" of the offset when defined.

    Have I ran into a bug?
    Please use plain text.