Strydaris Posted Thursday at 06:24 PM Posted Thursday at 06:24 PM Hi everyone, I have been looking around to see if anyone has made anything to help in the creation of a "Table of Contents". In my line of work, we need to match exactly the Drawing title to the Table of Contents reference and page number. For Example, the image below shows the ends result that I need. The image below shows what is under the drawings we produce. The title of this drawing is below in red. The above image is incorrectly labeled and should say "A4 MAIN FLOOR PLAN ELEVATION 'A' " (The 10' Ceiling part is not required generally). If there is multiple titles on a page then all of those need to be added to the ToC and might look something like this. A11 PARTIAL BASEMENT PLAN 'B' PARTIAL GROUND FLOOR PLAN 'B' PARTIAL SECOND FLOOR PLAN 'B' We currently use a formatted MTEXT to hold all this information where the A## is the page number on a new line and the contents is 2 tabs over. We use also use 2 columns for the list. So What I was thinking is having an auto numbering Page number in a lisp and then selecting the drawing titles to add next to the page number. In theory this will work but I have 2 major issues that I cant seem to get around right now. First, if the drawings titles that I select is an mtext with formatting, I cant find a way around removing the formatting. I am using ACAD 2024 LT and Lee Mac's "LM:Unformat string" doesnt work, neither does StripMtext. Does anyone have an idea to get around this? Secondly, I do not know how to build an mtext to include new formatting. Like how do you make sure you start a new line or add tabs before the next piece of text is added to the mtext? I am even up for other suggestions on how to create a Table of Contents.... except I cant use Sheet Sets. Our office doesn't want move in that direction just yet. Thanks. Quote
SLW210 Posted Thursday at 09:29 PM Posted Thursday at 09:29 PM https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/automated-sheet-index-lisp-assistance/td-p/9057520 Quote
BIGAL Posted 21 hours ago Posted 21 hours ago For me I use layouts and a Title block then can make an index of all layouts. Here is a copy of the code have a look at it. It looks from image that your using model space and not layouts. Dwgindex.lsp Quote
Strydaris Posted 13 hours ago Author Posted 13 hours ago @SLW210 Thanks. I will take a look at that. @BIGAL Thanks for the code. We stopped using sheet titles on our titleblocks. Sometimes we would end up having too many drawings on a single page and there wouldnt be enough room for it all on titleblock. We removed it and opted for a Table of Contents with all the labels. And yes we do primarily work in modelspace but all our current titleblocks are located in Paperspace. The drawing titles are located below the drawings in model space. Our table of contents is in modelspace as well. Our model space typically looks like this. Where as our Titleblock version of that looks like this ( the red blob is our company info blanked out)... The fields in the titleblock are linked to dwgprops for easy updating. Page # on the bottom right is a diesel expression that pulls the layout name. Anyways, the only method I can think about doing this is to select each drawing title in model space and have the lisp auto number the pages and organize in a table or formatted MTEXT. Quote
BIGAL Posted 3 hours ago Posted 3 hours ago (edited) If your making layouts then do that then go into mspace pick the page details than pop back to pspace and fill in your title block not that hard. Yes a lisp. One of the things I have looked at is pick a point on dwg in Model space, select scale, select title block and make the layout. You could add pick the mtext for title block also. It will cost you a cup of coffee as have to hard code the title block details etc. Edited 3 hours ago by BIGAL 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.