Click here to Skip to main content
15,886,799 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
To facilitate a software update, I have created a simple batch file that is updating a DLL in the program files directory with a new DLL from a predetermined folder path.

Example:

"copy C:\Temp\MyNewDLL.dll C:\Program Files\MySoftware\bin\"

How would I go about packaging the new DLL's with the batch file so the user does not have to move them to a specific folder first? Is it possible to package everything into one file that the user can just double click? Thanks!

Matt
Posted

1 solution

There are several ways, and I might note that what you are doing is a place where angels might fear to tread. At any rate:
- Put the updated DLLs in a zip file (you still will need to unpack it and execute something - this would be 2 steps for the user).
- Write an installer (the most robust method but requires the most work from you).

Also I would recommend the use of 'xcopy' (with different switches) rather than 'copy' as you have done here. What happens if the user tries to execute your script twice for example? [xcopy would fix that problem]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900