Web application : Classes
-
When I developed the website, I had put the classes which needs to be accessed throughout the application in App_Code. Now when I develop a web application, I don't see App_Code folder. Am able to drop them in App_GlobalResources folder and it works but I read it is for the global resource files. What is the best practice and where should I drop the class files?
Thanks
-
When I developed the website, I had put the classes which needs to be accessed throughout the application in App_Code. Now when I develop a web application, I don't see App_Code folder. Am able to drop them in App_GlobalResources folder and it works but I read it is for the global resource files. What is the best practice and where should I drop the class files?
Thanks
-
Hi there, 1) Right click on the project in the solution explorer 2) Choose Add ASP.NET Folder --> Choose App_Code Now you can add your classes there :)
Best Regards 3ala2 :)
That is not possible since ASP.Net folder consists of only App_GlobalResources, localresources, Data, Browsers and Theme. On a web application, am not able to add App_Code. On a web site, as you said, am able to. Where should I drop the global class files on the web application?
Thanks
-
That is not possible since ASP.Net folder consists of only App_GlobalResources, localresources, Data, Browsers and Theme. On a web application, am not able to add App_Code. On a web site, as you said, am able to. Where should I drop the global class files on the web application?
Thanks
You are correct, there is no option for App_Code, I just ran into this the other day. You can simply make a folder manually by that name and asp.net will recognize it as something to be compiled separately. However if you are making a web application rather than a web "site" it won't matter where you put the classes as they will be compiled into the entire assembly anyway.
When everyone is a hero no one is a hero.