Invalid Plot Config - AutoCAD Crash

Discussion in 'AutoCAD' started by egcallis, Dec 13, 2004.

  1. egcallis

    egcallis Guest

    This issue only occurs when we attempt to use an in-house vba plot routine to plot views from model space. The offending drawings always have a invalid plotter config assigned to the model layout. If we first use the plot button and acknowledge the invalid plotter configuration and chose a valid plotter and either save (on page setup) or plot, our vba routine then works fine.

    If we don't then AutoCAD errors out as follows

    ...
    ---------------------------
    AutoCAD Error-abort
    ---------------------------
    Error handler re-entered. Exiting now.
    ---------------------------
    OK
    ---------------------------


    The code snippet is as follows:
    where sPlotterCfg is a valid ConfigName
    ..
    ThisDrawing.ActiveSpace = acModelSpace
    Set aLayout = ThisDrawing.ModelSpace.Layout
    aLayout.ConfigName = sPlotterCfg '<- Error Occurs Here
    aLayout.RefreshPlotDeviceInfo

    How can we clear or reset the model layout plotconfig?
     
    egcallis, Dec 13, 2004
    #1
  2. In addition to any replies you might receive or already
    received, you may find more information or responses
    by posting future VBA related questions in the following
    discussion group:

    By NNTP discussion group reader at
    news://discussion.autodesk.com/autodesk.autocad.customization.vba

    By HTTP (web-based) interface at
    http://discussion.autodesk.com/forum.jspa?forumID=33

    --
    Autodesk Discussion Group Facilitator



    to plot views from model space. The offending drawings always have a invalid
    plotter config assigned to the model layout. If we first use the plot button
    and acknowledge the invalid plotter configuration and chose a valid plotter
    and either save (on page setup) or plot, our vba routine then works fine.
     
    Jason Piercey, Dec 13, 2004
    #2
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.