That looks very similar to mine but my lisp routine is named tbnp.lsp and mine handles previous sheet and next sheet. It adds the previous sheet value to the PREVSHEET attribute in the titleblock and the next sheet value goes to the NEXTSHEET attribute in the titleblock.
The following is added to the end of the WD_TB attribute. Must have the semicolon as a delimiter.
;PREVSHT = (if (setq x (findfile "tbnp.lsp" ))(progn(load x)(crevsheet)) " ");NEXTSHT = (if (setq x (findfile "tbnp.lsp" ))(progn(load x)(c:nextsheet)) " ")
Be sure your lisp file is named the same as the call from your WD_TB.
If there is a smiley face in the code string above that is caused by this forum. The smiley face should be a colon followed by the letter p.
after looking closer, i found it.
what's listed is missing a ( before the PROGN. it should show as
(IF (SETQ X (FINDFILE "TITLEBLOCK UPDATE.LSP"))(PROGN(LOAD X)(C:NEXTSHEET)) " ")
then it works.
thanks for the look Doug.
Does anyone else have a copy of this LISP ZIP file? I try to download it but it says that it is corrupted.
Here it is.
Many thanks! Very handy and was a quick fix to something someone asked for.
That's ALWAYS a good thing.
Well this has been working just fine until today. I've added two new drawings and neither of them will update the Next/Prev attributes.
I've checked and they are the same title block as others that do still work. Even exploded it to check that the code is indeed in the WD_TB attribute. Nothing else I know of has changed. Any ideas what might cause this to not work on a particular drawing(s)?
Start with some of our most frequented solutions to get help installing your software.
The AutoCAD Electrical forum has moved into it's very own category page, and can no longer be found within the Additional Product Forums.