400_the_cat
400_the_cat

Reputation: 883

ASP.NET - Is there a max number of .aspx pages your app should have?

I know an ASP.NET app can have as many aspx pages as you want but after hitting a certain number of them (over 100) should I consider a different design? Or, as the months/years go by do I just keep adding more and more pages to my app?

Upvotes: 1

Views: 218

Answers (3)

Rahul Soni
Rahul Soni

Reputation: 4968

There is a concept called batch compilation in Asp.net. By default the value is true and it comes into effect only when debug is false. In production when you have debug = false, all the files in one folder get compiled into 1 dll because of batch compilation. The number of files that can be batch compiled together is 1000.

Coming to your question.

  1. If you have more number of files in 1 folder JIT compilation will take longer.

  2. First request in a folder will seem a bit slower because of JIT compilation.

Hence you should neatly categorize your files into multiple folders. There is no such hardlimit to the number of files you can have.

Upvotes: 2

tucaz
tucaz

Reputation: 6684

I believe the only restriction is the cost of upkeep. This doesn't sound like a very organized (or designed) app if you need so many pages unless you have a valid reason of why you will need that amount of aspx files.

Upvotes: 0

Shyju
Shyju

Reputation: 218762

Organize it with folders.Ex:you can have user related files like edituser.aspx,userlist.aspx,viewuser.aspx etc in a folder called User.This way you can make your solution looks much cleaner.

Upvotes: 0

Related Questions