Web Development

General discussion


MS Access ListBox change color

By rac.techrep ·
Is there a way to change the back or fore color on a ListBox/Columlist object? I've been trying to use the forecolor or backcolor property but it changes the entire columlist and I need only the row with a specific condition to be a different color. Any tip is appreciated.


This conversation is currently closed to new comments.

Thread display: Collapse - | Expand +

All Comments

Collapse -

by dryflies In reply to MS Access ListBox change ...

in looking through the help section I could not find where you can change the color of the selected item in a list box. The selected item color is based on the background color and the font color (fore)

Collapse -

by rac.techrep In reply to

The problem is that I would like to display a column based on a criteria in a different color and not the selected item. For example if amount >1000 set row color = red. So, when the ListBox displays all items, that particular row will be red in the list and it will standout.

Collapse -

by salini_m_s In reply to MS Access ListBox change ...

pls try this code using asp

<SELECT id=select1 name=select1>
<% dim i
for i=1 to 10%>
<OPTION value=<%=i%><%if i mod 3=0 then%>
style="COLOR: sienna;"
<%else %> style="COLOR: blue;" <%end if%>%=i%></OPTION>

Collapse -

by rac.techrep In reply to

Thanks, but the issue is in VB not ASP. I know how to do it in ASP. I was looking for a VB answer. It seems that it is not supported at this moment. Thanks all for you replies.

Related Discussions

Related Forums