When creating a new web form the default page class is System.Web.UI.Page. Can this default be changed in visual studio 2010 so that it uses a custom class that we created that inherits from System.Web.UI.Page?
Cheers!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This requires editing a file within a zip.
Open:
C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\ItemTemplatesCache\CSharp\Web\1033\WebForm.zipExtract and edit
default.aspx.cs. Modify as you like!Save that file back into the .zip.
Repeat the same in
C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\ItemTemplates\Cache\CSharp\Web\1033\WebForm.zipAny new webform items you add to projects will contain the modifications you made.
Ensure the changes are in both
ItemTemplatesandItemTemplatesCache.