Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Windows batch
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 11-Mar-13 7:16am

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

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]
  Permalink  

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

  Print Answers RSS
0 OriginalGriff 195
1 ProgramFOX 130
2 Maciej Los 105
3 Afzaal Ahmad Zeeshan 82
4 Sergey Alexandrovich Kryukov 75
0 OriginalGriff 6,564
1 Sergey Alexandrovich Kryukov 6,048
2 DamithSL 5,228
3 Manas Bhardwaj 4,717
4 Maciej Los 4,150


Advertise | Privacy | Mobile
Web01 | 2.8.1411022.1 | Last Updated 11 Mar 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100