Wednesday, 3 August 2016

batch file - How do you find the current user in a Windows environment?



When running a command-line script, is it possible to get the name of the current user?



Answer



You can use the username variable: %USERNAME%


No comments:

Post a Comment

c++ - Does curly brackets matter for empty constructor?

Those brackets declare an empty, inline constructor. In that case, with them, the constructor does exist, it merely does nothing more than t...