1.

Solve : COPY A FILE TO DESKTOP (XP)?

Answer»

hi everyone!

need help in COPYING a FILE so that it will be visible in the DESKTOP.
just like shortcuts!

what will be the directory then?
the problem is that the path is not fixed like...
C:\Documents and Settings\comp1\Desktop
C:\Documents and Settings\comp2\Desktop
C:\Documents and Settings\comp3\Desktop
C:\Documents and Settings\comp4\Desktop
C:\Documents and Settings\comp5\DesktopTry:

"%userprofile%\Desktop"
"%allusersprofile%\Desktop"

Those work for XP and should work with Vista/7. The second will work for all user accounts on that computer and the FIRST will work for the current user (the one who ran the batch file).
C:\>cd \

C:\>dir /s  desktop
 Volume in drive C has no label.
 Volume Serial Number is 0652-E41D

 Directory of C:\Users\marylane

07/26/2010  10:13 AM              Desktop
               0 File(s)              0 bytes

 Directory of C:\Users\Default

07/13/2009  09:04 PM              Desktop
               0 File(s)              0 bytes

     Total Files Listed:
               0 File(s)              0 bytes
               2 Dir(s)  293,939,007,488 bytes free

C:\>COPY "P:\A\T\H\*.*" %USERPROFILE%\Desktop

Use quotes if there are spaces involved.THANKS to all! now I can complete my trial installer^^



Discussion

No Comment Found