Page 1 of 1

Random Tech Question

Posted: 14 Nov 2007, 18:30
by Argh
Sorry to bug everybody, but I can't remember how to do this...

How do you put a file onto a generic Windows user's desktop, from the command-line?

I've written a very simple script, and it has a section at the end where it's supposed to dump ipconfig/all into a text file, like so: ipconfig/all > C:\macadd.txt

After sending this out, I've found that users want this information on their Desktop (yes, people, there are lots of folks who find looking at the C:\ root confusing). I know there's a generic way to refer back to the Desktop for the user, but I can't remember what it is... something like %username%blahblah... anybody know what I'm supposed to put there?

Posted: 14 Nov 2007, 18:44
by lurker
%userprofile%\Desktop
no idea if it works on 9x though

Posted: 14 Nov 2007, 19:18
by Argh
Doesn't matter, all the users are 2K / XP... thanks very much, I knew it had to be something simple!

Posted: 14 Nov 2007, 19:29
by Pxtl
Not sure that'd work - you can customize your desktop folder to be outside of your user folder.

Sure there's not a %Desktop% or something?

Posted: 14 Nov 2007, 19:36
by KDR_11k
Nope. You can try it youzrself, open cmd and type "set".

Posted: 14 Nov 2007, 19:57
by Argh
None of these people will have customized the location of the desktop, trust me :roll: