Anjali
Anjali

Reputation: 2698

make portions of checkbox text bold

How can I make some portions of the checkbox text bold. I have the following checkbox:

<asp:CheckBox ID="chkPart1" runat="server" Text="To obtain a" + <b>"valid"</b> + "Copy you must check the appropriate box below:" + <b>"I am:" + </b>" /> 

I want to make Valid and I am bold in the above text so I want something like this:

enter image description here

I tried writing the code this way:

To obtain an valid Copy you must check the appropriate box below: I am:

and this is what I am getting:

enter image description here

Upvotes: 0

Views: 674

Answers (1)

Ranjit Singh
Ranjit Singh

Reputation: 3735

Create an input type checkbox with label

<input type="checkbox" id="chkPart1" runat="server" Text="" /> <label for="chkPart1">
  To obtain a <b>valid</b> Copy you must check the appropriate box below: <b>I am:</b>
</label>

Upvotes: 1

Related Questions