Show Zero as Red and Bold in ListBox (1 Viewer)

Sebsboutique

New member
Local time
Today, 08:22
Joined
Jun 27, 2022
Messages
7
Hi all,

I think i know the answer to this already, but i thought i would ask the clever chap(esse)s in this forum as to whether it could be done.

I have a listbox that displays inventory in my database. I currently have got to the stage where i have the "Inv_Qty" in the listbox showing up as red by converting it to a string in the Query and applying '[Red]@' in the format box for that column.

I wondered if there was a way of ONLY making the Zero Values Red and also making them bold, by applying some sort of fancy Format code in the format part of that Columns Properties?

Thanks in advance,
Seb :0)
 

Minty

AWF VIP
Local time
Today, 08:22
Joined
Jul 26, 2013
Messages
10,374
Have a read of this thread

for some ideas
 

CJ_London

Super Moderator
Staff member
Local time
Today, 08:22
Joined
Feb 19, 2013
Messages
16,668
you can create a subform which you can make look like a listbox and use conditional formatting.

Suspect you have already seen it but see this link by @isladogs


Colour should not be a problem, but bold would be

if you change your 0 to null and use the format

@;[red]"0"

code for 0 to null - probably a more elegant way but try

iif(myfield=0,null,myfield)
 

Users who are viewing this thread

Top Bottom