Sign in to follow this  
Followers 0
AmericanCheese

Find Current user?

4 posts in this topic

#1 ·  Posted (edited)

I need a way to get the current user and store it as a global variable. 

 

So they run it, and it will store the username "C: etc etc"

Also need it to be emailed to me, how to do that aswell??

Any idea's / example scripts?

Edited by AmericanCheese

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

MsgBox("", "Username", @UserName)

There are also a few other macros for saved paths.

MsgBox("", "Current User Start Menu Programs Directory", @ProgramsDir)
MsgBox("", "Current User Favorites Directory", @FavoritesDir)
MsgBox("", "Current User App Data Directory", @AppDataDir)
MsgBox("", "Current User Dekstop Directory", @DesktopDir)
MsgBox("", "Current User Profile Directory", @UserProfileDir)

 

Edited by InunoTaishou

Share this post


Link to post
Share on other sites
3 minutes ago, InunoTaishou said:
MsgBox("", "Username", @UserName)

 

Follow up question, how do I send myself an email?

Share this post


Link to post
Share on other sites

There are a few ways to approach this. This search will bring up what you want. I've done this before and just used this one by Jos using an email I made on gmail just to email my personal email address.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0