Is there a way to set the Preferences/Username for each user? Easiest would be a script step from filemaker, but really anything would work, primarily running on Windows and Mac not to worried about fmGO and don't use WebDirect.
Put the code to set the fields and/or global variables in your "On First Window Open" script - I usually refer to it as the "startup" script. It always runs as the file opens from a cold start.
If you don't have a startup script, define one in the file's "Options" settings.
I'm 95% sure this cannot be done. Perhaps a Powershell or similar script could be written that would set the value through the Windows registry but it is unlikely that FM could execute a Powershell script without a lot of manual security changes being made first.
Sorry, then I misunderstood your question. I though you wanted to set a global field in the Preferences table such as "Preferences::gAccount" to Get( AccountName ) or Get( UserName).
You mean to set FileMaker's username in preferences?
That should be doable with MBS FileMaker Plugin and Registry functions (Windows) and Preferences functions (Mac).
Does anyone know the Registry location and Preference I would need to edit?
Thanks for the MBS plugin tip, can't believe there isn't a way to set this in filemaker.
From my examples:
MBS( "Registry.GetValue"; "HKEY_CURRENT_USER\SOFTWARE\FileMaker\FileMaker Pro Advanced\16.0\Preferences"; "User Name")
This is for 16, but you can change number to 17 if needed.
I do not know any native way of doing this in FileMaker, but I suggest that you create a Product Ideas
for this I will vote for it
I made a suggestion for it,
Set Username in Preferences
Someone else has a similar request to use something else than username in server logs which is a major part of why I want to set username.
Show Connected User on Server Activity Log
Retrieving data ...