Click here to Skip to main content
15,888,047 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi use load controls ASCX or use master page ASPX which is better? why?
i'm sorry for my poor english.
Posted
Comments
Karthik. A 17-Sep-12 15:32pm    
They serve 2 different purposes in a way. Master page - setup the layout for the entire project, like, where a menu appears, the styles for various elements etc. User controls - Say you want to provide an information about a product which has to be displayed in 2 pages, then, you could create a user control. So, it all depends on your needs. Expand your question to include that information and looking in to a tutorial that explains these things will be of great help to you...
[no name] 17-Sep-12 15:57pm    
I would upvote this as being a solution....
Maciej Los 17-Sep-12 16:36pm    
I agree with Wes Aday. My virtual 5!
Sergey Alexandrovich Kryukov 17-Sep-12 21:06pm    
That said, the OP's question is totally incorrect. The two does not have some absolute values; it depends what to use for what. What is "better"? -- something that needs definition and may or may not be defined. I would also up-vote this comment if it was an answer; so I advise to put such posts as answers.
--SA
Karthik. A 18-Sep-12 9:23am    
Thanks to all! As Sandeep already posted a solution and it's also accepted, I am going to let it pass! Thanks again!

1 solution

ASPX is a webform page extension where as ASCX is a usercontrol extension.

They are totally different and their usage easily defines what should be used. ASPX alone can be hosted in an app and can be browsed but ASCX cannot. To access controls of ASCX, you need some ASPX. Generally, ASCX will be collection of controls that is used at various place whereas ASPX is a normal webpage that will have various controls and ASCX in them.

Use the one based on your need.
 
Share this answer
 
Comments
Maciej Los 17-Sep-12 16:36pm    
Good answer, my 5!
Sergey Alexandrovich Kryukov 17-Sep-12 21:07pm    
The matter of things is explained, my 5; and OP should think about correctness of questions...
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900