essaytee
Need a good one-liner.
- Local time
- Tomorrow, 07:08
- Joined
- Oct 20, 2008
- Messages
- 542
In Access VBA when creating Excel spreadsheets, how do I extract the default font color?
I have a routine where I cycle through a recordset and one particular field has one of three possible values, a positive number, zero or negative number, that are text fields, not numbers. (It's a leaderboard table and this field indicates the position move of the person from the previous leaderboard). I know how to set the color of the relevant cell, but I don't know how to refer to the default font color (other than not referring to it and obviously the default font color is set). For fields I'd rather set the color directly, after the color is determined, rather than continual if/else routines.
I'm setting the color like so:
In my Googling, I did see references to Conditional formatting, and I'll certainly look at that afterwards, but at the moment I'd like to know how to directly refer to the default font color.
I have a routine where I cycle through a recordset and one particular field has one of three possible values, a positive number, zero or negative number, that are text fields, not numbers. (It's a leaderboard table and this field indicates the position move of the person from the previous leaderboard). I know how to set the color of the relevant cell, but I don't know how to refer to the default font color (other than not referring to it and obviously the default font color is set). For fields I'd rather set the color directly, after the color is determined, rather than continual if/else routines.
I'm setting the color like so:
Code:
Sheet1.Range(strRange).Font.Color = vbBlue
In my Googling, I did see references to Conditional formatting, and I'll certainly look at that afterwards, but at the moment I'd like to know how to directly refer to the default font color.