8
Answers

Copy file and then rename file

Ask a question
Drew Taylor

Drew Taylor

17y
16.4k
1

I want to be able to allow a user to select a file in a listbox which displays files from a location they have specified, they then click copy which makes a copy of the file they have selected, then I want to to allow the user rename the copied file and then have the file sent to a specified folder.

I have tried to make this work but I'm not sure what the best way to do it is? (also not sure of the code needed)

Currently I have a browse button which allows the user to select a location to read the files from, which then populates a textbox they then click open and a listbox is populated with the files. The user then selects/Highlights a file in the listbox and clicks the copy button, this copies the selected file and adds copied to the end of the file - how can I allow the user to rename the copied file? Is a better way to allow them to have one button that does all of this?

If you think you know how to do this, please help!


Answers (8)