Click here to Skip to main content
15,907,905 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionHelp in Web.Config file Pin
Biju Sam27-Jun-07 18:08
Biju Sam27-Jun-07 18:08 
AnswerRe: Help in Web.Config file Pin
sathesh pandian27-Jun-07 18:30
sathesh pandian27-Jun-07 18:30 
GeneralRe: Help in Web.Config file Pin
Biju Sam27-Jun-07 18:40
Biju Sam27-Jun-07 18:40 
GeneralRe: Help in Web.Config file Pin
sathesh pandian27-Jun-07 18:42
sathesh pandian27-Jun-07 18:42 
GeneralRe: Help in Web.Config file Pin
Biju Sam27-Jun-07 19:09
Biju Sam27-Jun-07 19:09 
QuestionHelp with dropdownlist [modified] Pin
ASPnoob27-Jun-07 17:46
ASPnoob27-Jun-07 17:46 
AnswerRe: Help with dropdownlist Pin
postmaster@programmingknowledge.com27-Jun-07 18:34
postmaster@programmingknowledge.com27-Jun-07 18:34 
QuestionConfused About Skinning User Controls Pin
expinch27-Jun-07 16:40
expinch27-Jun-07 16:40 
I am writing my own user control and I'm wondering how to control its appearance in .NET 2.0. We can call my control 'PlayerTemplate' and it represents a template for a player in the NFL. The appearance of this control will be dictated by the team that the respective player plays for. Here is a small chunk of what the control is currently comprised of:

<!-- PAYTON MANNING -->
<div class="playerTemplate indianapolisColts">

<!-- Main Ranking Section -->
<div class="rankContainer">
<h3>1</h3>
</div>

<!-- Team Color Division -->
<div class="teamColorContainer teamColors">
<div class="colorDiv teamColor1 teamColorBorders"></div>
<div class="colorDiv teamColor2 teamColorBorders"></div>
</div>

<!-- Player Section -->
<div class="playerContainer teamColors">
<table class="playerTable">
<tr>
<td rowspan="2" class="helmetCell">
<a href="" class="helmetLink"></a>
</td>
<td class="playerCell" style="">#18 Payton Manning | QB</td>
</tr>
<tr>
<td class="teamCell">I.N.D. Colts, 8 years exp</td>
</tr>
</table>
</div>
</div>


My stylesheets are configued such that I only have to change the second css class of the main element to get the desired visual effects throughout all of the html elements of the control:

<div class="playerTemplate indianapolisColts>">

and the associated classes for the colts:

/* INDIANAPOLIS COLTS (eventually translate to a skin) */
.indianapolisColts .teamColors {background-color:white;border-top:1px solid #596267;border-bottom:1px solid #596267;}
/*teamcolorsection*/
.indianapolisColts .teamColorContainer .teamColor1 {background-color:#003B7B;}
.indianapolisColts .teamColorContainer .teamColor2 {background-color:#AEB6BB;}
/*helmet*/
.indianapolisColts .playerContainer .playerTable a.helmetLink {display:block;width:31px;height:24px;background-image:url(../../images/coltshelmet.gif);}

and another team for good measure....

/* NEW ORLEANS SAINTS (eventually translate to a skin) */
.newOrleansSaints .teamColors {background-color:#ffebbf;border-top:1px solid #564826;border-bottom:1px solid #564826;}
/*teamcolorsection*/
.newOrleansSaints .teamColorContainer .teamColor1 {background-color:black;}
.newOrleansSaints .teamColorContainer .teamColor2 {background-color:#cbb073;}
/*helmet*/
.newOrleansSaints .playerContainer .playerTable a.helmetLink {display:block;width:31px;height:24px;background-image:url(../../images/saintshelmet.gif);}


As you can see, I have my team classes organized such that the sub-elements of each playerTemplate get defined based on the top-level team css class.

I was trying to figure out how to do all of this using skins, but because I'm designing a custom user control I'm wondering if that is overkill. I could pretty easily expose a property called 'Skin' in my user control and apply the necessary team css class directly to the top level <div> and be done with it, but I'm wondering if I would gain something by implementing it through skins instead.

All of the skin examples I've seen are used to style known controls, does it even make sense to try to implement skinning for a custom-written user control? Obviously you'd have to add the SkinID to the usercontrol yourself, but how do you then associate that skin property back to a .skin file? I'm lost.


QuestionIf my GridView isn't bound to a SqlDataSource the edit control doesn't work Pin
InvalidTypecast27-Jun-07 15:57
InvalidTypecast27-Jun-07 15:57 
QuestionWhich is Better? Pin
Kasson27-Jun-07 15:38
Kasson27-Jun-07 15:38 
AnswerRe: Which is Better? Pin
Venkatesh Mookkan27-Jun-07 16:57
Venkatesh Mookkan27-Jun-07 16:57 
GeneralRe: Which is Better? Pin
Kasson27-Jun-07 17:17
Kasson27-Jun-07 17:17 
AnswerRe: Which is Better? Pin
accessred27-Jun-07 18:22
accessred27-Jun-07 18:22 
GeneralRe: Which is Better? Pin
Kasson27-Jun-07 18:34
Kasson27-Jun-07 18:34 
GeneralRe: Which is Better? Pin
_AK_27-Jun-07 19:54
_AK_27-Jun-07 19:54 
GeneralRe: Which is Better? Pin
accessred27-Jun-07 20:15
accessred27-Jun-07 20:15 
AnswerRe: Which is Better? Pin
Sathesh Sakthivel27-Jun-07 18:50
Sathesh Sakthivel27-Jun-07 18:50 
GeneralRe: Which is Better? Pin
Kasson27-Jun-07 18:53
Kasson27-Jun-07 18:53 
AnswerRe: Which is Better? Pin
sathesh pandian27-Jun-07 18:53
sathesh pandian27-Jun-07 18:53 
GeneralRe: Which is Better? Pin
Kasson27-Jun-07 18:55
Kasson27-Jun-07 18:55 
AnswerRe: Which is Better? Pin
Sathesh Sakthivel27-Jun-07 19:03
Sathesh Sakthivel27-Jun-07 19:03 
GeneralRe: Which is Better? Pin
Kasson27-Jun-07 19:07
Kasson27-Jun-07 19:07 
GeneralRe: Which is Better? Pin
sathesh pandian27-Jun-07 19:36
sathesh pandian27-Jun-07 19:36 
GeneralRe: Which is Better? Pin
Kasson27-Jun-07 19:40
Kasson27-Jun-07 19:40 
GeneralRe: Which is Better? Pin
Vasudevan Deepak Kumar27-Jun-07 21:37
Vasudevan Deepak Kumar27-Jun-07 21:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.