A permanent font installation is needing administrative permissions.
AddFontResource documentation tells you it will only make a font available to a session, not permanently.
[URL unfurl="true" said:
https://learn.microsoft.com/en-us/windows/win32/api/wingdi/nf-wingdi-addfontresourcea[/URL]]This function installs the font only for the current session. When the system restarts, the font will not be present. To have the font installed even after restarting the system, the font must be listed in the registry.
On the other side, you also only need the font in your application, don't you? So you can make the AddFontResource call at every start of your application to be able to use it within your application. Indeed, it then will not list as a font when you browse c:\windows\fonts, because it's not installed, actually, it's just added to the fonts for your own process/application, but this could be sufficient.
If you have the need to create docx or other files that other applications like MS Word should also be able to display and print with that font, the straight forward way is to really install the font with a setup you should do for your application anyway. It's a feature of installers like Inno setup to also install fonts.
Chriss
PS: Regarding the quote end "...the font must be listed in the registry", This is not detailed there, so the simplest option surely is installing the font in the setup of the application.