Community
Civil 3D Forum
Welcome to Autodesk’s Civil 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Civil 3D topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Corridor Section Editor Display problem when using multiple viewports

8 REPLIES 8
SOLVED
Reply
Message 1 of 9
Jay_B
1366 Views, 8 Replies

Corridor Section Editor Display problem when using multiple viewports

We're having a Section Editor display issue in our template.
Whenever the Viewport Configuration is set to anything other than "Single" this causes the Plan Viewport to cover the other VP's and the other VP's can't be activated.

 

Works fine in our 2012.dwt
Also works fine in the OOTB _AutoCAD Civil 3D (Imperial) NCS.dwt
In our 2014.dwt (which was migrated from our 2012.dwt) is where things get strange.

 

The problem appears when changing the VP Layout to any multiple configuration option.

In command Settings for ViewEditCorridorSecttion we have the Apply Viewport Configuration option turned off.

 

Has anyone seen this issue before?

 

2014.dwt with the issue

 

sec view 2014 custom.PNG

 

2014 Imperial OOTB.dwt

 

sec view 2014. OOTB.PNG

 

2012.dwt

 

sec view 2012.PNG

 

C3D 2018.1
C3D 2016 SP4

Win 7 Professional 64 Bit
8 REPLIES 8
Message 2 of 9
Jay_B
in reply to: Jay_B

Eidt: Using the "Three Above:" option as shown, the viewports can all be activated by using ctrl R, then it's cycling through 4 viewports.

 

I just don't know of a way to get rid of the 4th viewport covering the entire drawing area?

C3D 2018.1
C3D 2016 SP4

Win 7 Professional 64 Bit
Message 3 of 9
Jay_B
in reply to: Jay_B

The solution to this issue was rebuilding the template.

Now the Model Space Viewports are functioning properly.

C3D 2018.1
C3D 2016 SP4

Win 7 Professional 64 Bit
Message 4 of 9
jrampello
in reply to: Jay_B

We have this exact problem, we get the 3 viewports from the tool but still have the one large viewport.  what specifically did you focus on when you rebuilt the template??

Jim
Message 5 of 9
Jay_B
in reply to: jrampello

Hi Jim,

 

Didn't really focus on anything in particular but rebuilt the affected templates from scratch.

 

There's a lot that goes into rebuilding an entire template.

 

I'd recommend starting with the OOTB C3D Imperial NCS.dwt as the starting point.

 

 

 

 

C3D 2018.1
C3D 2016 SP4

Win 7 Professional 64 Bit
Message 6 of 9
Cadguru42
in reply to: Jay_B

This happens to to me in a template created from the acad.dwt for 2016 where I use a two viewport split. I just click in the viewport and use the middle mouse to pan and it regenerates correctly. 

C3D 2022-2024
Windows 10 Pro
32GB RAM
Message 7 of 9
jrampello
in reply to: Cadguru42

Does this make the overall modelspace viewport disappear or do you just get the info "out of the way"?

Jim
Message 8 of 9
Cadguru42
in reply to: jrampello


@jrampello wrote:

Does this make the overall modelspace viewport disappear or do you just get the info "out of the way"?


It just cleans the screen as is supposed to look. 

C3D 2022-2024
Windows 10 Pro
32GB RAM
Message 9 of 9

This is caused by a viewport that Civil 3D did not clean up. This usually occurs when a user undoes the Corridor Section Editor command instead of using the close button. The code below deletes all of the model space viewports and starts from scratch, including the bad viewport.

using (var tr = db.TransactionManager.StartTransaction())
{
    var vpTable = db.ViewportTableId.GetObject(OpenMode.ForWrite) as ViewportTable;

    foreach (var vpObjId in vpTable)
    {
        var vpTblRec = vpObjId.GetObject(OpenMode.ForRead) as ViewportTableRecord;

       

        if (vpTblRec.Name.Equals("*Active", StringComparison.OrdinalIgnoreCase) || 
            vpTblRec.Name.Equals("Civil 3D Section Editor Viewport Configuration Snapshot", StringComparison.OrdinalIgnoreCase))
        {
            vpTblRec.UpgradeOpen();
            vpTblRec.Erase();
        }
    }

    using (var vpRightTblRec = new ViewportTableRecord() { Name = "*Active", LowerLeftCorner = new Point2d(0, 0), UpperRightCorner = new Point2d(0.5, 1) })
    {
        vpTable.Add(vpRightTblRec);
        tr.AddNewlyCreatedDBObject(vpRightTblRec, true);
    }

    using (var vpLeftTblRec = new ViewportTableRecord() { Name = "*Active", LowerLeftCorner = new Point2d(0.5, 0), UpperRightCorner = new Point2d(1, 1) })
    {
        vpTable.Add(vpLeftTblRec);
        tr.AddNewlyCreatedDBObject(vpLeftTblRec, true);
    }

    vpTable.DowngradeOpen();

    ed.UpdateTiledViewportsFromDatabase();

    tr.Commit();
}

 

 

Civil Reminders
http://blog.civil3dreminders.com/
http://www.CivilReminders.com/
Alumni

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Rail Community


 

Autodesk Design & Make Report