# Visual basic 2008 installer



## hockeyfreak863 (Feb 8, 2008)

i am trying to make an application copy a file that is in the resources i want to copy it from the resource file to somewhere like the desktop this is the code i have so far and it dosnt work i need help making it.

My.Resources.Objects_server.CopyTo()
("C:\users\Administrator")


----------



## pvc_ (Feb 18, 2008)

I'm not sure what you mean by resource file, but if you want to copy a file in general, you could use "system.io.copy()"


----------



## hockeyfreak863 (Feb 8, 2008)

when i use that code it gives me an error "Copy is not a part of io"


----------



## DoubleHelix (Dec 10, 2004)

System.IO.File.Copy

Most Vista systems are not going to have a C:\Users\Administrator directory. Regardless, where are you going to copy the file _from_? If it can be copied, it can be accessed. I wouldn't want any program copying files anywhere on my hard drive without my explicit consent or outside of a defined, standard, installation procedure.


----------



## pvc_ (Feb 18, 2008)

sorry, yeah I forgot the "file" part.


----------



## pvc_ (Feb 18, 2008)

C:\ProgramData might be a better place for vista.


----------



## hockeyfreak863 (Feb 8, 2008)

DoubleHelix said:


> System.IO.File.Copy
> 
> Most Vista systems are not going to have a C:\Users\Administrator directory. Regardless, where are you going to copy the file _from_? If it can be copied, it can be accessed. I wouldn't want any program copying files anywhere on my hard drive without my explicit consent or outside of a defined, standard, installation procedure.


im trying to make an installer, Under the users discretion, all i need it to do is copy a .zip file from the attached resources and paste it into a game folder, its a mod. The reason im putting it into an insall.exe is because people are telling me they cant get it to work


----------

