Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.

Programmatically make the difference between Inventor & AutoCad .dwg

FINET_Laurent
Advisor

Programmatically make the difference between Inventor & AutoCad .dwg

FINET_Laurent
Advisor
Advisor

Hi folks,

 

I have a list of .dwg files. I would like to remove the AutoCad .dwgs & keep the Inventor .dwg.

How can I make the difference between the two programmatically ? 

 

Kind regards,

FINET L.

If this post solved your question, please kindly mark it as "Solution"

If this post helped out in any way to solve your question, please drop a "Like"

@LinkedIn     @JohnCockerill

0 Likes
Reply
Accepted solutions (1)
225 Views
3 Replies
Replies (3)

WCrihfield
Mentor
Mentor

Interesting issue.  Have you already checked tried opening each of them in Inventor, then using the DrawingDocument.IsInventorDWG property?  I have never tested it myself before, because we use IDW for all our drawings, so the only DWG's we have are from AutoCAD.

Wesley Crihfield

EESignature

(Not an Autodesk Employee)

0 Likes

WCrihfield
Mentor
Mentor
Accepted solution

Another one to test might be the ThisApplication.FileManager.IsInventorDWG() method, which will actually take a String type input, instead of having to open, then use a DrawingDocument object.

Wesley Crihfield

EESignature

(Not an Autodesk Employee)

FINET_Laurent
Advisor
Advisor

Dear @WCrihfield

 

gods-gifts.jpg

 

Kind regards,

FINET L.

If this post solved your question, please kindly mark it as "Solution"

If this post helped out in any way to solve your question, please drop a "Like"

@LinkedIn     @JohnCockerill