Government Security
Network Security Resources

Jump to content


Batch = %userprofile% Vb 2008 = ?

  • Please log in to reply
2 replies to this topic

#1 ROG Onafets

ROG Onafets


  • Members
  • 4 posts

Posted 07 February 2010 - 11:05 PM

Hi All
I'm teaching myself VB Nows! Posted Image

I know that the command when you copy folders in User directories for batch is %USERPROFILE% but what is it in VB 2008?

Stupid question I know but hey! Posted Image

Please reply ASAP! Posted Image

#2 Juza



  • Sergeant Major
  • 149 posts

Posted 09 February 2010 - 10:50 AM

Dim fileP As String

fileP = My.Computer.FileSystem.SpecialDirectories.MyDocuments



Go to
Follow me

The true beginning of our end.

#3 ROG Onafets

ROG Onafets


  • Members
  • 4 posts

Posted 12 February 2010 - 01:28 AM

Thank you soo much m8!

I couldn't for the life of me work this out.

So to copy a file it would be:

fileP = MyComputer.FileSystem.SpecialDirectories.MyDocuments

FileCopy("&fileP&\Test.bat", "&fileP&\Test Folder\")

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users