I am refactoring a web app built with previous versions of Asp.Net MVC where all the views have 2 codebehind files each.
Also if the views are working correctly I want to begin to remove all the code behind files as most of them are empty.
There are few of them that have properties like this in the codebehind:
public partial class List {
public Message NewMessage { get { return new Message(); } }
}
Before completely removing them (I know this methods do not pertain to the views) how do I replicate them in the single page aspx or ascx?
I just tried to copy and paste the public methods in <% %> tags but this is not working.