At the end of August I had the chance to go to my home country to continue the evangelism on Autodesk new Large Model Viewer web service API. Always with the desire to give back part of my experience and knowledge to my home country, I decided to reach out to my Tech contacts in order to make these talks possible and expand my network with the Guatemalan Tech enthusiasts. The response I got from 5 of the Top Universities in Guatemala was simply amazing.
My Tech Evangelism tour started with #CampusTEC and Universidad Del Valle, where I had the opportunity to share how the Web is changing, and how Autodesk believes that 3D web should be something that starts taking over, we are a big 3D CAD design and software company, the tools exist and seeing the beautiful CAD designs that get created, should be available in your Web.
Later, during the week, I was made the opening Key note speaker at a great Tech Innovation Forum at Galileo University #FITGT, where I share my opinion and experience about Design, Education and 3D web, and how Design should be consider as one of the new pillars in education. With the many makers, we have around today, it just makes sense that these young enthusiasts get a head start shaping their minds to acquire great design skills and create new amazing things, in my opinion. A big thank you to Oscar Rodas. Adrian Catalan, Maria Zaghi and Yucely Beb for making these talks possible.
After a successful day spending time with many innovators and makers from Guatemala, I went to Universidad Rafael Landivar, where an audience of 200 aspiring engineers (Mechanical, Civil, Software) were eager to learn about how to add their Inventor, Revit, AutoCAD models on their own website. Big thanks to Boris Ruiz for the organization of this great group of students.
During my last days in Guatemala, I had the chance to meet with the Director of the new Computer Science department at Universidad Francisco Marroquin, where I had the chance to present the technology to 1st year students of the CS department and many have already started to reach out, eager to know how to make their Web 3D enabled. Thanks to Leonel Morales for hosting me.
I see there is a lot of potential in Guatemala when it comes to the Tech Business, I will keep you up to date on how what I showed turns out.
Ok, enough of my traveling and evangelism experience, back to the Revit API. This week I had a chance to work and play with a command that deletes the imported CAD from your Revit Project. Something that got addressed by Harry Mattison from Boost Your BIM blog back in 2013. After seeing his nice post on it, I was curious to check if everything he shared will still work with Revit 2016 and sure it did.
Here is the question in our Revit API forum, posted by Vinay.
Is there any possibilities of deleting imported cad through API.
Answer by Dale Bartlett: I have used this successfully:
(Document doc, bool pblnIncludeLinks)
using (Transaction tr =
new Transaction(doc, "DeleteImports"))
foreach (ImportInstance ii in new
Where(i => i.IsLinked == pblnIncludeLinks))
Adding to the Answer: The suggestion that Dale gave you is a great one, But I see that only works for Earlier versions of Revit 2013 and earlier probably. I read the source from where he got it and I noticed that the Author also recreated it for 2014. I tested myself using Revit 2015 and 2016 and it seems to be working fine with the imported CAD files.
Here is how the Command looks.
public class Command : IExternalCommand
public Result Execute(
ref string message,
UIApplication uiapp = commandData.Application;
UIDocument uidoc = uiapp.ActiveUIDocument;
Application app = uiapp.Application;
Document doc = uidoc.Document;
public void deleteImportsNotLinks(Document doc)
IList<ElementId> toDelete = new List<ElementId>();
foreach (ImportInstance ii in new
.Where(i => i.IsLinked == false))
using (Transaction t = new Transaction
(doc, "Delete Imports"))