When I export a SharePoint list to Excel using the built-in functionality, it also exports two columns called Item Type and Path.
Is there a way OOTB or programatically to exclude these columns from the export?
If the export is data that users will routinely access in Excel, you can hide the Item Type and Path columns in Excel, and then create a data connection between the workbook and the list. Each time the workbook is opened the list data will be updated in Excel and the columns remain hidden. Click here for step-by-step instructions for creating the data connection. When I use this method, to make access easy for users, I add a link to the workbook on a web page in a site.
You can use the SharePoint List API to do this, start here: msdn article
Alternatively, you can try opening the list in DataSheet view and cut-and-paste the block of rows and columns that you are interested in.