Conditional formatting and html

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm using Access 2003. I have a report the uses conditional formatting. In
the right condition the text of a field turns red.

It works fine when viewed in Access. It also works great when I export to
Snap format. However, if I export to html the whole column turns red, rather
than just the particular rows that meet the criteria.

I've tried exporting with default encoding, Unicode, and Unicode (UTF-8),
all with the same results. They offer a template option, but I don't know
how to construct a template, and I'm not sure it would help if I did.

It seems to be an Access bug. Does anyone know of a work around?
 
CF is not required for Reports. Simply use the Format event of the
relevant section to modify the desired COntrol(s) properties.

--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
Stephen,

Actually I guess I got confused between my forms and reports. In the report
I do use the report format to set the color, not CF, however, I still have
the problem in HTML. My coding looks like the following:

Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)

If NextTestLatest < Date And Not (Not IsNull(Extension) And Extension >=
Date) Then
txtName.ForeColor = 255
txtName.FontWeight = 900 'Bold
txtName.FontItalic = True
NextTestLatest.ForeColor = 255
NextTestLatest.FontWeight = 700
NextTestLatest.FontItalic = True
Else
txtName.ForeColor = 0
txtName.FontWeight = 400 'Normal
txtName.FontItalic = False
NextTestLatest.ForeColor = 0
NextTestLatest.FontWeight = 400
NextTestLatest.FontItalic = False
End If
End Sub
 
Sorry Leif, I know from several KB articles that CF does not export well
at all. I had hoped that programmatically setting the props would work
but obvioulsy it does not.

I would suggest you post again in a new thread focusing on the possible
template solution.

Good luck.

--

Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
Back
Top