Brando569 Posted May 23, 2005 Posted May 23, 2005 hey im tryin to delete shortcuts off of the quicklaunch through a batch file but for some odd reason windows cant get to it! ive tried atleast 3 or 4 different ways to get to it and it still doesnt work. these are the things ive tried:del %homepath%\applic~1\Microsoft\Interne~1\QuickL~1\ad-wat~1.lnkdel %appdata%\Microsoft\Interne~1\QuickL~1\ad-wat~1.lnkdel %systemdrive%\profiles\bran\applic~1\micros~1\interne~1\quickl~1\adwatc~1.lnkand a few others, even when i try to go to just %systemdrive%\profiles\bran\applic~1 it says it cant find the path, but yet %systemdrive%\profiles\bran\ and %appdata% work (well %appdata% works at the run box but not in a cmd prompt). whats wrong?
MHz Posted May 24, 2005 Posted May 24, 2005 I do not think you can mix variables with 8.3 format. If you cannot do it from a cmd prompt, then it will not work in a batch file. They use the same interpreter.Use this:Del "%APPDATA%\Microsoft\Internet Explorer\Quick Launch\Ad-watch.lnk"
Brando569 Posted May 26, 2005 Author Posted May 26, 2005 good job, you solved the mystery i guess ill just have to rely on my system drive being c: editi just realized something you CAN use vars with 8.3 above the lines with %appdata% i have these lines and they work perfectly!del %systemdrive%\Profiles\AllUse~1\Desktop\nerost~1.lnki guess %appdata% and 8.3 dont play well together....
DonDamm Posted May 29, 2005 Posted May 29, 2005 If you put your original ones in quotes, they should work. %Appdata% expands to seveeral directories which have spaces in them. %systemdrive% does't, so you don't have the problem there. Don't bother using the 8.3 names. Just put the whole thing in quotes and Bob's your uncle!
Brando569 Posted May 30, 2005 Author Posted May 30, 2005 If you put your original ones in quotes, they should work. %Appdata% expands to seveeral directories which have spaces in them. %systemdrive% does't, so you don't have the problem there. Don't bother using the 8.3 names. Just put the whole thing in quotes and Bob's your uncle!<{POST_SNAPBACK}>good thinkin! will try it out. and is bob really my uncle?i was wonderin who my uncle was.... thanks now i can sleep peacefully..
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