I'm writing a tool to change iproperties in the titleblock.
But now we start using two different types of titleblocks.
I need to check which titleblock is present in the current sheet/drawing.
I use this code to place a titleblock:
Call Doc.ActiveSheet.AddTitleBlock("sample_titleblock")
How do I check if "sample_titleblock" is already present?
Try something like...
Dim currentTBname as string
currentTBname = Doc.ActiveSheet.TitleBlock.Name
if currentTBname = "sample_titleblock" ...
You will have to place error catching code for the event that no title block exists on the document, the line currentTBname = Doc.ActiveSheet.TitleBlock.Name throws a Object Not Set type error.