"It alway stuck with "Admin" when I logged in with other accounts" - probably becasue it is not set to be 'Unstored'
Ah! - "Un-stored calculation works, but then its not global so I can't put it on un-related layout nor use it in multi-user" - why can an unstored calculation not be global?
Why not just make it a calculation field, Get ( AccountName ), global, unstored?
Thank Sorbsbuster, but I cant click both "Global" and "Unstored" in the calculation -> option - > storage option, clicking one will untick the other. This sort sensible as "Unstored" is part of index property and "Global" can not be indexed.
Another issue with "Unstored" is that the field on layout shows "<index missing>" not matter related or not, but when you click into it, it shows the right get(accountname) value, and other function based on this field works ok, I couldn't understand such behaviour.
Had similar issue in another post http://forums.filemaker.com/posts/f8b5b9331b#132315
There is something different about our understanding. I have created a file with a calculation field 'AccountName'. It is set to be Get (AcciountName ). It is a calculation, set to global. By definition therefore it is unstored and unindexed. I created two accounts. I created a 'Re-login' script. When I log in on one account it shows me the user name Admin1. When I use the script to re-log in it correctly shows me the user name Admin2.