How to reference Microsoft.Office.Interop.Excel dll?

calendar_today Asked Mar 8, 2013
thumb_up 35 upvotes
history Updated April 16, 2026

Question posted 2013 · +25 upvotes

I had developed a system that deals with excel sheets in 2006 using MS VS 2005. Now, I can not use the same reference with MS VS 2012.

var app = new Microsoft.Office.Interop.Excel.Application();
Workbooks wbs = app.Workbooks;

Accepted answer +35 upvotes

In your project, right-click on “References” and select “Add Reference”.

VS 2012 / 2013:

Select “Extensions” on the left and look for Microsoft.Office.Interop.Excel.

Note that you can just type “excel” into the search box in the upper-right corner.

VS2012/2013 References

VS 2008 / 2010:

Look under the .NET tab.

VS 2010 References

Excel VBA objects referenced (5)

Top excel Q&A (6)

+35 upvotes ranks this answer #13 out of 167 excel solutions on this site — top 8%.