sugarfly Posted April 5, 2013 Posted April 5, 2013 Hi All, I am working with PowerShell and Windows 7 libraries. I am successful with removing a library, adding a new one but I am coming up at a loss adding the currently logged in users 'My Music' folder to the library. I presume that it is not liking the %userprofile% on the add folder. The issue is that there could be other users on this computer and all users are on a domain. Any help would be appreciated! @echo off Echo Remove Music Library del "%userprofile%\AppData\Roaming\Microsoft\Windows\Libraries\Music.library-ms" pause Echo Create Music library for current user (run in user context) shlib create "%userprofile%\AppData\Roaming\Microsoft\Windows\Libraries\Music.library-ms" pause shlib add "%userprofile%\AppData\Roaming\Microsoft\Windo ws\ Libraries\Music.library-ms" "%userprofile%\My Music" Pause
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now