asp.net pluggable pages

T

Trapulo

I've a requirenment that maybe its too hard to have, but I hope someone has
a good suggestion...

Basically, I need to create some pluggable pages in an asp.net application.
The pages are simple data management related (search data, shows, edit, and
so on). The Business Entities, BLL and DAL layer have a pluggable system to
create personalization of some objects, and I need to create a GUI related
to the provider the application is using.
An example:
- I can have and order entity, with some properties
- I can have an asp.net layer that users use to retrieve (with filter
options on the existing properties), edit and save orders
- now I subclass the order entity and related classes (DAL methods to
save/retrieve, etc), to create a structure customized to a specific client.
I use a class factory with a configuration file to create all classes
related to order, as using a provider pattern. My app creates instances of
the subclasses items, and all can work (I think).
- now, how can I load the right GUI based on same configuration settings? I
need to mantain a single web application because there are a lot of
functions that are shared, but I need that my GUI "shows the right pages",
plugged as the logic is.

I hope it's clear...

Is there any pattern to have this goal?
thanks
 
B

bruce barker \(sqlwork.com\)

look at the model-view-controller pattern.

-- bruce (sqlwork.com)
 
S

Steven Cheng[MSFT]

Hello Trapulo,

From your description, what you want to do is building a pluggable/dynamic
presentation layer which will display different GUI interface on web
according to the different client consumers, correct?

Based on my experience, to build such as dynamic web application
presentation system, you can consider the following options(depend on the
flexibilty and control granularity you want):

1.According to different client users, you can create multiple ASP.NET ascx
usercontrols which have different user interface(controls and processing
code behind logic...). At runtime, on the main page, you can dynamically
load the usercontrols according to the client user. This approach require
us to predefine those usercontrols and won't give 100% dynamic creation.
However, it is the preferred approach if you have limited number of client
users that will need customized GUI. Also, it will make the development
much easier.


2. You can 100% dynamically create the UI of an ASP.NET web page since
ASP.NET support dynamically create server controls. You can store the
different GUI layout of page in database(such as control's type and
location) and at runtime dynamically create and add those controls onto
page. I've ever met some ones who use XML file or content to store such
layout info.

Here are some information about create dynamic UI in ASP.NET:


http://support.microsoft.com/kb/317794

http://www.beansoftware.com/ASP.NET-Tutorials/Dynamic-User-Interface.aspx

http://dotnet.sys-con.com/read/38932.htm

Hope this helps some. If you have any further questions or any other
consideration on this, please feel free to post here.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead



==================================================

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.



Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.

==================================================



This posting is provided "AS IS" with no warranties, and confers no rights.
 
T

Trapulo

Hello Steven,
I think I'll use your suggestion #1.
This way requires I create a single monolithic asp web layer and not a
really pluggable component (as I do for bll and dal), but I have not too
many customers so it can be a good solution because it's very simple to
implement.

Thanks
 
S

Steven Cheng[MSFT]

Thanks for your followup Trapulo,

Yes, the #1 approach is quite convenient for implement and we can leverage
design-time support for contructing UI.

Good luck!

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead

This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top