hutch@edge.net
Joined: 16 Sep 2008 Posts: 77
|
Posted: Wed Nov 04, 2009 7:33 pm Post subject: [SOLVED] How to get windows user name |
|
|
Greetings, Gurus.
I have a short hotstring that enters the date and username into a program when you type "ed{Enter}"
| Code: |
::ed:: ;;Edit MM/DD by ______.
Send, Edit %A_MM%/%A_DD% by Jack Q.
Sleep, 100
Send, {F2}
Return
|
As you can see, it automatically enters the date, based on the current windows date. What I would like to do is, instead of having to edit the script for everyone who may use it, have it also enter the windows user's name. For example, instead of reading "Send, Edit %A_MM%/%A_DD% by Jack Q.", it would be something like, "Send, Edit %A_MM%/%A_DD% by %Current_User%."
Of course, %Current_User% isn't the correct syntax. Can anyone help?
Last edited by hutch@edge.net on Wed Nov 04, 2009 8:58 pm; edited 1 time in total |
|