AutoLISP Wizard Posted 18 hours ago Posted 18 hours ago Hi everyone, I’ve been working on a small production tool in AutoLISP/VLISP for AutoCAD / Civil 3D and thought it might be useful to share here for anyone doing a lot of section or profile sheets. ## What problem it solves On corridor / section jobs we often end up with several paper-space viewports that all need to: - Use the same scale and twist - Stay aligned to a centerline / path (alignment, guide polyline, etc.) - Be re-centered after design changes The usual manual workflow for us was: 1. Set up one “master” viewport with the correct scale, twist, layers, etc. 2. Copy that viewport across the layout for each station/section. 3. Manually PAN/ZOOM/DVIEW in each viewport to center the correct station along the path. 4. Repeat that pan/zoom step any time the design or alignment changed. It works, but it’s tedious and easy to make mistakes when you have a lot of sheets. ## What SectionSync LITE does SectionSync LITE is a compiled VLX that: - Lets you pick a polyline path (e.g. alignment, section chain, etc.) - Associates multiple paper-space viewports with positions along that path - Updates the view center of each viewport so it “follows” the path - Preserves the existing viewport scale and twist - Can be re-run after design changes so you don’t have to manually re-pan everything It was written mainly with Civil 3D section/profile sheets in mind, but it’s just working with standard AutoCAD viewports and a polyline. ## Technical notes - Written in AutoLISP/Visual LISP and compiled to VLX for distribution. - Uses vla/vlax functions to read and set viewport center, width/height, and twist. - Path positions are based on cumulative distance along the selected polyline. - No reactors or custom objects – it just runs on demand and updates existing VPs. ## Demo + download Short demo video: https://youtu.be/l1JRbz4_owQ Download / more details (there’s a built-in 5-run / 7-day trial so you can test it on a real project): https://autolispwizard.gumroad.com/l/civabs If anyone is interested in the implementation details (polyline parameterization, handling UCS and VP twist, etc.) I’m happy to discuss approaches or share pseudo-code for the core parts. 1 Quote
BIGAL Posted 44 minutes ago Posted 44 minutes ago (edited) Welcome aboard,. Nice idea doing two vports per sheet. For where I worked it was a plan view at top and the corresponding long section below. We used Civil Site Design as an add on so it did all this in the package. Runs on CIV3D or Bricscad. Yep like this I did years ago, also pick a point, make repeated rectangs based on a hor/ver pattern. All rotate the viewport where required. have done around 70+ in one go. You could move, rotate, add or delete a rectang then make layouts. Draw rectangs.mp4 Something you may be interested in draws grid in paperspace based on viewport including twisted vport. Has a dcl front end for control of how grid looks. Edited 36 minutes ago by BIGAL Quote
rlx Posted 36 minutes ago Posted 36 minutes ago First of all , welcome to Cadtutor AutoLisp Wizard! My kind of work is 99% electrical & instrument loop diagrams so I don't often have to work with viewports and when I do its just for simple cabinet views and some instrument layouts. But I do appreciate users who contribute and share their hard work with other users , so although I'm not gonna use it my self , thank you for your contribution. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.