Error while trying to add a new content page

Today, while I was trying to add a new content page to a web application, using Microsoft Visual Studio, after choosing the “New Item” option and checking the option “Select master page”, by clicking the “Add” button, I received the following error:

Could not find a part of the path ‘C:\Program Files\Microsoft Visual Studio

I fixed the problem by restoring the default project templated as mentioned here.