EneergE Posted June 20, 2011 Share Posted June 20, 2011 Some shortcuts from C:\ProgramData\Microsoft\Windows\Start Menu\Programs do not appear to be responsive to a CLI "del" or "move."For an example, "Windows Media Player" by default appears in ProgramData's start menu directory, but the CLI can not see it.When you attempt to delete or move this shortcut using a CMD window, an error occurs that states that the shortcut does not exist. However, if you browse to the exact same location using Explorer, you can move and delete the file as you wish.I've been developing some batch scripts to tidy up the start menu after a post install, but this is driving me bonkers. This occurs on Windows Vista, also. On Windows Vista, the "Windows Meeting Space" shortcut can not be removed or deleted using the command line, but it's a piece of cake using Explorer.I've also checked user specific Start Menu\Programs\ folder and they are not in that location, either. The properties for the shortcut shows ProgramData. I see it with explorer, but CMD can't see it. I, also, launched CMD with Admin privileges.Does anyone know why the CLI can not see these files, yet Explorer has no problem? Link to comment Share on other sites More sharing options...
Yzöwl Posted June 20, 2011 Share Posted June 20, 2011 The CMD Prompt can see the particular file you mentioned!Try providing us with the exact commands you are issuing, their respective results and an indication of when and how you are running them. Link to comment Share on other sites More sharing options...
EneergE Posted June 22, 2011 Author Share Posted June 22, 2011 Ok, was a little busy, but I managed to grab this screen shot of a Vista install where the CMD can not see "Windows Meeting Space".On Windows 7, I can't remember the exact shortcuts it was that had that problem. I'm pretty sure it was Windows Media Player, though. I could not ever figure out how to remove that start menu shortcut using a script. Link to comment Share on other sites More sharing options...
Tripredacus Posted June 22, 2011 Share Posted June 22, 2011 I know what you are saying now. let me use an example from my system. In my Start Menu, Windows Update shows up, and the properties say the shortcut exists in the path you posted about. However, in that folder (from explorer) that shortcut does not exist. There are file links between files in some folders, so they actually live somewhere else. Here are some possible locations:C:\Users\Default\AppData\Roaming\Microsoft\Windows\Start MenuInstead of Roaming, there may be a Local folder. My PC does not have a Windows folder in Local. Go to C:\Users\Default\AppData to see what you have. The Public folder does not have an AppData folder, or at least (again) my PC doesn't. Link to comment Share on other sites More sharing options...
allen2 Posted June 22, 2011 Share Posted June 22, 2011 Windows 7 is full off hardlinks , junctions, symbolic links and in this case it is probably because there is a junction above. Link to comment Share on other sites More sharing options...
jaclaz Posted June 22, 2011 Share Posted June 22, 2011 If it's a hard link, instead of guessing the location , one could use hlscan.exe ....This is the 2K version, it should work on later OS versions too (at least it does on XP):http://www.microsoft.com/downloads/en/details.aspx?FamilyID=289adee4-abb3-4e18-ab07-c77db8654979&displaylang=enIf it's a junction (symbolic directory link) , one can use junction.exe ...http://technet.microsoft.com/en-us/sysinternals/bb896768jaclaz Link to comment Share on other sites More sharing options...
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