copying file help

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • shinyrory
    Forum Member
    • Sep 2006
    • 17

    copying file help

    Hey

    If someone is trying to copy a file to a directory where there is a file with the same name is there a way to ask the end user for confirmation before over writing the original file? I want to use the File.Copy command instead of the File.Install command so i can use a customized dialog box. Thanx for your help
  • bobbie
    Forum Member
    • Feb 2005
    • 770

    #2
    This help?
    Code:
    -- Checks to see if a particular file exists.
    are_ya_there = File.DoesExist(_WindowsFolder.."\\targetfile.ini");
    
    -- If the file does not exist, display a message notifying the user.
    if are_ya_there == false then
        result = Dialog.Message("Notice", "The specified file does not exist.", MB_OK, MB_ICONINFORMATION, MB_DEFBUTTON1);
    end

    Comment

    • shinyrory
      Forum Member
      • Sep 2006
      • 17

      #3
      thanx for that bobby but i wanted something that would check to see if the file already exists and then display a dialog box saying "are you sure your want to overwrite the original file" "yes or no" type thing. thanx again

      Comment

      Working...
      X