• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

How to create a program that will replace a file?

cudzich09

Banned
So I want to create a program that will replace a file. I dont know how to do that, I looked around with google but could only find something like visual patch or patch maker. Is this the program that I should be using to create patches?


I only want to replace an old file (sample.exe) with the new file(sample.exe). I want to create a program that will do it automatically.


Thanks
 
First, a couple of questions. What language do you want to use? Are you familiar with any? Is the file going to be in the same place on every computer?
 
So a patch program is probably more than you need for your simple task. It boils down to a set of operations. 1) check the version of the existing file; 2) copy it if it needs to be replaced.

You can do this in any programming language, including cmd shell script, depending on how you define "need to be replaced." It might be a simple date/time check, or it might involve checking the version number in the executable file.

So what do you need to check to know whether the file should be replaced? We can take it from there.
 
Back
Top