Community
Inventor Programming - iLogic, Macros, AddIns & Apprentice
Inventor iLogic, Macros, AddIns & Apprentice Forum. Share your knowledge, ask questions, and explore popular Inventor topics related to programming, creating add-ins, macros, working with the API or creating iLogic tools.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Inventor crashing with new 3D Annotations in drawing

7 REPLIES 7
Reply
Message 1 of 8
DWhiteley
274 Views, 7 Replies

Inventor crashing with new 3D Annotations in drawing

I have found that Inventor 2018 crashes when using GetRetrievableDimensions if the model document contains the new 3D Annotations:

 

 

Dim oDims As GeneralDimensions
oDims = osheet.DrawingDimensions.GeneralDimensions

 

For Each oView In oViews

  oRetDims = oDims.GetRetrievableDimensions(oView)

 

 

 

(Works fine in 2017)

 

Dave Whiteley

Envisage UK Ltd

7 REPLIES 7
Message 2 of 8

Hi Dave,

 

Please try the following sample code.

 

Dim oDims As GeneralDimensions
oDims = oSheet.DrawingDimensions.GeneralDimensions

For Each oView in oViews

      Dim objColl As ObjectCollection
      objColl = oDims.GetRetrievableDimensions(oView)

Next

 

If still Inventor crashes, then please provide document which contains 3 D annotation.

 

Please feel free to contact if there is any doubt.

 

If solves your problem, click on "Accept as solution" / give a kudo.

 

Thanks and regards,


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network



Message 3 of 8

Hi Chandra,

 

I just took out the line oRetDims = oDims.GetRetrievableDimensions(oView)

 

This fixed my problem of Inventor 2018 crashing:

 

For Each oView In oViews

 

 ''oRetDims = oDims.GetRetrievableDimensions(oView)

 ''If oRetDims.Count > 0 Then


 Try
   Dim dimsEnum As GeneralDimensionsEnumerator
   dimsEnum = oDims.Retrieve(oView)

 Catch ex As Exception

 End Try

 

 

Next

 

 

I still believe there is a problem with GetRetrievableDimensions with parts that have 3D annotation added to them.

 

Dave

Message 4 of 8

Hi Dave,

 

Can you please specify about declaration of oRetDims variable?

 

Actually, GetRetrievableDimensions(oView) method returns ObjectCollection. So, oRetDims should be declared as ObjectCollection.

 

Please provide 3d annotation part file, if it is non confidential.

 

Thanks and regards,


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network



Message 5 of 8

Dim oRetDims As ObjectCollection

 

Model attached.

Message 6 of 8

Hi Dave,

 

I can also reproduce crash, if the model contains tolerance feature annotations.

 

So, I checked with engineering team. It is a known issue.

 

Thanks and regards,


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network



Message 7 of 8

Ok, thanks Chandra. Is this likely to be fixed soon?



Dave







---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus
Message 8 of 8

Hi Dave,

 

Yes, It will be fixed soon.

 

Thanks and regards,


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network



Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report