Import vs Link CAD files

I have an issue with people linking and importing CAD files. Is it possible to get an alert when someone Imports a CAD file? The difference would be - Link requires me to go – manage - Manage Links - Cad Formats - Add. To import I would – Insert - Import CAD.

Not sure of the best way to go about getting this information.

In the discovery view I see that the action - Export File Data with a Command of “Transaction Successful” comes up when I Import a file. I also get the same data when I link a file…

Anyway it is getting late so I will look again in the morning…

Thank you!!

@Gilly we do have an event in revit-log called File Imported but unfortunately at the moment it doesn’t distinguish between imports and links of CAD files. I didn’t realize that we weren’t doing that so I added that in and will make that available in the next release. It will look like this:

As you can see there will be a new boolean property file.isLinked so for imports it will be set to false.

That’s for the next release though. How about now. Through the revit-journal index you can see when someone imports by catching an event called Import as Link when Action is set to 0 which means that it was imported. If it was set to 1, it would have been linked.

Does that help?

Yes this helps - I will start with this one and look forward to the next release.

If you can not answer yet that is fine but I was wondering if you have a rough idea when the next release might be?

Thank you!!

@ksobon - FYI - It would be nice to be able to get the project information - It looks like we will get that when the update comes out. Moving to revit-log…

Thanks

@Gilly yes, project info will be in the revit-log once the update is out. Next release we are shooting for before the end of the year. If that fails early next year.

Following up on this topic. We have now released version 1.1.40, which includes boolean file.IsLinked under revit-log. This can be used to create an alert for when a CAD file is imported into Revit as opposed to being linked.

Additionally, project information is now captured within revit-log.

any chance this info will make its way into revit-user?

We cannot add a file.IsLinked parameter into revit-user due to how it is collecting data, which comes from from users’ journal file.

However, there is a way to distinguish between users importing CAD vs linking CAD.

When the Link CAD or Import CAD commands are used, revit-user logs several documents.

What we are looking for is the field Comid, which is ID_FILE_IMPORT for import events, and ID_FILE_CADFORMAT_LINK for link events.
image

Therefore, to get a count of how many times a user has imported CAD, you can create a metric for count of documents where Comid is ID_FILE_IMPORT

Note: Data view revit-journal is collecting information from the revit-user indices. The name is meant to reflect that the information is coming from the journal files.

In what case are you looking for this information from revit-user? revit-event provides a more direct solution and includes information on what Revit file the action was perfomed in, whereas revit-user does not.

To add to the above, our Revit - Selective Commands Traffic Light dashboard comes out-of-the-box, and includes a count of Import CAD events along with other not-so-best-practice events.

I meant the file project information in revit-user

The Revit journal doesn’t include information relating to the file the logs are coming from. but we’re actively working on a solution! It will be available in a future release.