MonoX support board

Start the conversation, ask questions and share tips and solutions with fellow developers.

Non-registered users can only browse through our support boards. Please register now if you want to post your questions. It takes a second and it is completely free. Alternatively, you can log in without registration using your credentials at major sites such as Google, Microsoft Live, OpenId, Facebook, LinkedIn or Yahoo.

How to change module appearance?  (Mono Support )

Viewed 19671 time(s), 2 post(s) 6/8/2009 1:41:43 PMby JoeUser


6/8/2009 1:41:43 PM
I want to change the look and feel of an existing module. The problem is that the module is not using the templating mechanism, as it does not include the repeating elements: it really simple and contains only a few textboxes and a button. However, I need several versions of the UI for this module, while the backend functionality will remain the same.
Any ideas?
This content has not been rated yet. 
26 Reputation 11 Total posts


6/8/2009 3:10:33 PM

there are several ways to change look and feel of the module.

1. You can implement custom css selector class and change appearance of the module with css classes (Maybe the easiest way)
2. You can use the "Two markup files on code behind" technique.

2.1 Tell your class that it is templated, in Constructor (IsTemplated = true;)
2.2 Create a folder for your module in "App_Templates/YourThemeName/ModuleName" and set "ControlSpecificTemplateSubPath" property of the module to "ModuleName"
2.3 Create a UserControl inside that folder, and use ActionBox template as an example

<%@ Control

<%--Options Start--%>
<%--Note: This ID is hard-coded--%>

<%--Options End--%>

<%--Content Start--%>
<%--Note: This ID is hard-coded--%>

<%--Content End--%>

2.4 Put as many as you want UserControls with all sorts of layouts inside the markup
2.5 Now you can load your templated layout with combination of „TemplateFullVirtualPath“ and „Template“ properties of BasePart
2.6 Now you need to put all of your controls dynamically to panels / content place holders

This content has not been rated yet. 
15993 Reputation 2214 Total posts