No replies
Mike55
Offline
newbie
Last seen: 13 years 26 weeks ago
Joined: 2008-01-02
Posts: 2
Points: 0

I have an asp.net panel inside of which I have a number of controls spread out over 3 lines.

The controls in each line are currently:
html label
asp.net label (optional)
asp.net textbox

The css mark-up for the html label is:
label {
float: left;
text-align: left;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 0.9em;
font-style: normal;
color: #000000;
width: 17em;
padding-left: 6px;
padding-right: 6px;
}

The css mark-up for the asp.net textbox is:
.FormItemStyle {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 0.9em;
font-weight: normal;
color: #006699;
border: 1px solid #006699;
}

With regards to the remaining control, the asp.net label. This control will only show sometimes. It consists of a * that is used to indicate required fields. If the user fails to submit data, the field's fore-color would be changed from black to red.

Not each line needs to have the asp.net label. I have tried to replace the label with   to act as a spacer between the html label and the asp.net textbox. Works most of the time but giving some problems.

Can anyone suggest a solution, I've switched the layout from a html table based version to css. Very impressed with the css.

Michael.