View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
seagroaa seagroaa is offline
external usenet poster
 
Posts: 1
Default Excel crashes when opening a template from VBA 2007

I have a template called Timetable.xltx in the folder
C:\Users\Andy\Documents\@Templates. The folder has been added to Excel as a
trusted location 'User Templates'.

When I create a file based on the template from the Excel menu File New
[Select Template] Create it opens OK.

However when I put the following code
Workbooks.Add "

into a workbook it causes Excel to crash with the message 'Microsoft Excel
has stopped working'