I’ve written a bit of iLogic code for a rather niche problem in Autodesk Inventor, but it is something that you may come up against at some stage, or something I may need to refer back to in the future!
When Inventor drawings are copied, particularly during a “File > Save As > Save Copy As” operation, the title block of the drawing will show the original save date of the initial drawing. If you were to then replace the reference models, the title block would again show the original part/assembly name.
The iLogic code I have written gets the model name and the current date and writes these values back to the drawing iProperties. Below is a GIF file showing how this works:
Here is the code:
'iLogic Code by Clint Brown, originally posted at 'https://clintbrown.co.uk/iLogic-Title-block 'Update the title block - with curent date and correct drawing name (from model) oGetTheName = ActiveSheet.View("VIEW1").ModelDocument.DisplayName oGetStringLength = Len(oGetTheName) oName = Mid(oGetTheName,1,(oGetStringLength-4)) iProperties.Value("Project", "Part Number") = oName iProperties.Value("Project", "Creation Date") = Now iLogicVb.UpdateWhenDone = True