how do I refer to a table cell within a CheckBoxList?

M

MattB

The relates to my question earlier about how to format labels in a CBL
(CheckBoxList) to not wrap.

I think I've found an approach that will probably work when I can figure out
how to refer to a cell within a CBL. Borrowing from what I've learned about
DataGrids, I've created a OnDataBinding event that fires when the CBL is
bound. Now I need to figure out how to refer to the table cells in there so
I can set their wrap property to False.

In a Datagrid, it would be:
dim cell As TableCell = e.Item.Cells.Item(i)

But this doesn't work for a CheckBoxList. Anyone know how to refer to a cell
in a checkbox list in the DataBinding event? Thanks!

Matt
 
Joined
Oct 12, 2006
Messages
1
Reaction score
0
workaround

In this case, you could use CSS2:

<div style="border:1px inset; width: 200px; height: 100px; overflow-x: hidden; overflow-y:auto; background: white;">
<asp:checkBoxList id="lstProjects" DataTextField="xyzName" DataValueField="xyzID" width="500px" runat="server"/>
</div>
 

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

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,013
Latest member
KatriceSwa

Latest Threads

Top