Font style changing to Arial after closing and opening of Access File (1 Viewer)

EmEx

New member
Local time
Today, 17:47
Joined
Jan 25, 2021
Messages
26
I've never seen this behavior with Access other than when there was a licensing issue with Hattenschweiler font. Given that I have used some symbol fonts and some obscure fonts that SURELY could not be counted as having a "complete set of styles" - I don't think I have ever seen a font reset like that. The Hattenschweiler case was a "default font."

But something occurred to me. Are you by any chance using style sheets?

No sir. No style sheets whatsoever. In my example database its just a simple table and a simple report.

Edit: Additional Observation

It only affects unbound text boxes and labels...
 
Last edited:

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 04:47
Joined
Feb 28, 2001
Messages
27,140
If there is ANY kind of VBA code anywhere near any of this, I would try to isolate where it occurs by single-stepping to see if you can at least figure out what routine is doing this to you.
 

EmEx

New member
Local time
Today, 17:47
Joined
Jan 25, 2021
Messages
26
If there is ANY kind of VBA code anywhere near any of this, I would try to isolate where it occurs by single-stepping to see if you can at least figure out what routine is doing this to you.
I'm sure no VBA Code is causing this. Kindly look at my stripped down file:

Access DB File
 

JMongi

Active member
Local time
Today, 05:47
Joined
Jan 6, 2021
Messages
802
You might want to check out this thread for a possible solution.
 

EmEx

New member
Local time
Today, 17:47
Joined
Jan 25, 2021
Messages
26
You might want to check out this thread for a possible solution.
Interesting discussion but did not solve my case. What I did to "temporarily" fix the issue is this:

a. Avoid using font without complete styles (reg, ita, bold, bold ita) -#I might be wrong on this#
b. Avoid using styles outside of reg, ita, bold, bold ita)
c. I observed that the font problem affects Non Variable controls such as LABELS and UNBOUND TEXT BOXES.
d. If I really want to use other styles, (e.g. Black), I just put a code in the OnFormat event of the section and force the Style. Me.control.FontName, also I force the content of the control (Me.Control = "String") still on the OnFormat event of the section. Although there are remote cases the problem does go back.
 

onur_can

Active member
Local time
Today, 02:47
Joined
Oct 4, 2015
Messages
180
An idea came to my mind. Are you using a theme? It may be affected if you use it. As a solution, you can do as follows: Create a new empty database and transfer all the objects in your old application to this new database, so Fonts and colors will revert to default.
 

EmEx

New member
Local time
Today, 17:47
Joined
Jan 25, 2021
Messages
26
An idea came to my mind. Are you using a theme? It may be affected if you use it. As a solution, you can do as follows: Create a new empty database and transfer all the objects in your old application to this new database, so Fonts and colors will revert to default.
I may or may not have used a theme I cannot remember but opening theme menu I cannot find a no theme option. I did tried transferring all objects to new database and at first it solved the problem... but.. after numerous closing and opening the problem comes back... I am starting to think I am right about my points above....
 

EmEx

New member
Local time
Today, 17:47
Joined
Jan 25, 2021
Messages
26
Just to be sure about it.. I created another access db and transferred all objects... here it is.. the problem is still persistent
 

Attachments

  • new_problematic.accdb
    768 KB · Views: 92

JMongi

Active member
Local time
Today, 05:47
Joined
Jan 6, 2021
Messages
802
I downloaded you problematic DB and did see the issue you were describing. But, the following steps have seemed to solve it:
1. Open the DB
2. Go to File > Options > Current Database
3. Deselect "Use Windows Themes on Form Controls"
4. Open the report in design view.
5. Click the Font Theme dropdown
6. Select the "Custom" font theme.
7. Highlight all of the report controls.
8. Select the Font Theme dropdown and select "Custom"
9. Select each individual control and reselect the preferred font type (either from the ribbon or the properties menu).
10. Save

I have closed and reopened the DB 5 times now without a change.
Edit: I've closed/reopened a handful of more times with no change. I'll try it again as I'm working and see if something pops up.
 

EmEx

New member
Local time
Today, 17:47
Joined
Jan 25, 2021
Messages
26
I downloaded you problematic DB and did see the issue you were describing. But, the following steps have seemed to solve it:
1. Open the DB
2. Go to File > Options > Current Database
3. Deselect "Use Windows Themes on Form Controls"
4. Open the report in design view.
5. Click the Font Theme dropdown
6. Select the "Custom" font theme.
7. Highlight all of the report controls.
8. Select the Font Theme dropdown and select "Custom"
9. Select each individual control and reselect the preferred font type (either from the ribbon or the properties menu).
10. Save

I have closed and reopened the DB 5 times now without a change.
Edit: I've closed/reopened a handful of more times with no change. I'll try it again as I'm working and see if something pops up.
Wow. Tried your procedure again sir. I think this is a breakthrough solution for this particular problem. Thanks so much. We could be on the right path here.
 

JMongi

Active member
Local time
Today, 05:47
Joined
Jan 6, 2021
Messages
802
No problem. I hope the fix stays fixed!
 

onur_can

Active member
Local time
Today, 02:47
Joined
Oct 4, 2015
Messages
180
So the problem was in using different themes, as I mentioned.
 

JMongi

Active member
Local time
Today, 05:47
Joined
Jan 6, 2021
Messages
802
It's not quite that simple, but it is related to themes. Access and Windows don't seem to play nice when it comes to themes. It leads to some unexpected flaky behavior at times.
 

EmEx

New member
Local time
Today, 17:47
Joined
Jan 25, 2021
Messages
26
So the problem was in using different themes, as I mentioned.
You are absolutely right, but I do not remember clicking the theme menu or toying with the different themes so it did not come to my mind that the cause is due to using different themes, or theme related. The real cause apparently is customizing the font manually (in the format section) while the "apply theme on controls" option is turned on. (y) But I think this is still in the observation stage right now if this solution will last. Hopefully, it will. Thanks for all the input and suggestions.
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 04:47
Joined
Feb 28, 2001
Messages
27,140
Congratulations to those who provided the solution. And it makes sense.
 

Users who are viewing this thread

Top Bottom