You will not be able to access class of aspx.cs page inside app_code folder unless you put it under App_Code folder. There may be a workaround to avoid moving the aspx.cs by using BaseClass. You can find the details
here.
And yes, if you use "web application" you can access aspx.cs class inside app_code folder without any issue.