How to retrieve the current user's home directory from either Command Prompt or PowerShell:
C:\> cmd /c "echo %homedrive%%homepath%"
C:\Users\andrew
PS C:\> cmd /c "echo %homedrive%%homepath%"
C:\Users\andrew
How to retrieve the current user's home directory from either Command Prompt or PowerShell:
C:\> cmd /c "echo %homedrive%%homepath%"
C:\Users\andrew
PS C:\> cmd /c "echo %homedrive%%homepath%"
C:\Users\andrew