Change font color in report

P

Phillip

Hi,
I have a form (titlepage) with a command button that prints a report
(titlereport). The report has a text box that gets its data from a memo
field in a table. I would like to add a drop-down box (fontcolor) on the
form to allow the user to select the font color that would print in the
report. Is this possible and of so what code do I need?
Your help would be appreciated.
Thanks,
Phil
 
S

Steve

Put your fontcolor drop-down box on your titlepage form. Make it unbound.
Put the following code on the open event of the report:
Me!NameOfMemoTextbox.fontcolor = Forms!TitlePage!Fontcolor

Note two things:
1. TitlePage form must be open when report opens
2. fontcolor combobox must return the codes for the colors; not just the
name of the color.

Steve
(e-mail address removed)
 
D

Duane Hookom

I would start by creating a table with the color names and their numeric
values. Bind the numeric value column in a combo box named "cboColor". If you
want all fo the records to have the same color, add code to the On Open event
like:

Me.txtMyTextBox.ForeColor = Forms!frmYourForm!cboColor
 

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

Similar Threads

Printed Report Font 1
won't print color 1
Change text color in report 2
Dcount the values 0
missing data 2
Report sorting 1
Change font by user before printing labels 2
Access Access Report Works on One Machine but not Another 3

Top