About a text box

S

Simon

Dear Sir/Madam,

In a form I have created a text box containing the following code :

=Trim([Fld_1_C]) & " ( " & Format([Fld_2_N];"Standard") & " - " &
Format([Fld_3_N];"Standard) & " )"

Except from the standard form given, I would like to know whether, the value
of the field “Fld_2_N†- if lower or higher than another value - its color
can change (only within this particular part of the text box).
 
D

Dale Fye

What version of Access are you using? If you are using something prior to
2007, then I recommend putting each of the segments of your field in a
separate text box and set the conditional formatting of the box that displays
[fld_2_N].

If, however, you are using Access 2007, you could set the "Text Format"
property of the control (on the Data tap of the Property dialog) to Rich
Text. You could then wrap your control field text with html tags to set the
color of the text in the middle. It might look something like:

=Trim([Fld_1_C]) & " ( " _
& iif([fld_2_N] < 23, _
"<font color = ""#ED1C24"">", _
"<font color = ""#3399FF"">") _
& Format([Fld_2_N];"Standard") _
& "</font>" & Format([Fld_3_N], "Standard") & " )"

Cannot remember precisely which colors those are, but you can change the
color values to anything you want.
 
S

Simon

The version of Access is 2003.

Dale Fye said:
What version of Access are you using? If you are using something prior to
2007, then I recommend putting each of the segments of your field in a
separate text box and set the conditional formatting of the box that displays
[fld_2_N].

If, however, you are using Access 2007, you could set the "Text Format"
property of the control (on the Data tap of the Property dialog) to Rich
Text. You could then wrap your control field text with html tags to set the
color of the text in the middle. It might look something like:

=Trim([Fld_1_C]) & " ( " _
& iif([fld_2_N] < 23, _
"<font color = ""#ED1C24"">", _
"<font color = ""#3399FF"">") _
& Format([Fld_2_N];"Standard") _
& "</font>" & Format([Fld_3_N], "Standard") & " )"

Cannot remember precisely which colors those are, but you can change the
color values to anything you want.

----
HTH
Dale



Simon said:
Dear Sir/Madam,

In a form I have created a text box containing the following code :

=Trim([Fld_1_C]) & " ( " & Format([Fld_2_N];"Standard") & " - " &
Format([Fld_3_N];"Standard) & " )"

Except from the standard form given, I would like to know whether, the value
of the field “Fld_2_N†- if lower or higher than another value - its color
can change (only within this particular part of the text box).
 

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

Top