+ Reply to Thread
Results 1 to 2 of 2

Copy over files/replace (complete question)

  1. #1
    G3£Wh\)zZ@
    Guest

    Copy over files/replace (complete question)

    Cat walked over keyboard and actually sent the previous post uncomplete so
    here it is complete..thansk for reading.

    I have a lot of files on cd/dvd that i am moving into one folder on my hdd
    so i can sort them out before reburning them. However there are quiet a few
    mp3 files that have the same name etc but because i converted these at a
    higher bit rate they are larger in size, whilst moving them to the folder i
    keep getting the "would i like to replace the existing file" and have to
    click either yes or no.

    Its a pain ...so is there anything out there or anything i can do , that
    will only copy/replace the original file if the new file is larger in size..


    --
    The Source For Premium Newsgroup Access
    Great Speed, Great Retention
    1 GB/Day for only $8.95

  2. #2
    Mel Arquiza
    Guest

    RE: Copy over files/replace (complete question)

    Option Explicit
    Declare Function CopyFile Lib "kernel32" Alias "CopyFileA" (ByVal
    lpExistingFileName As String, _
    ByVal lpNewFileName As String, ByVal bFailIfExists As Long) As Long

    Public Function APIFileCopy(src As String, dest As String, _
    Optional FailIfDestExists As Boolean) As Boolean

    'PURPOSE: COPY FILES
    'PARAMETERS: src: Source File (FullPath)
    'dest: Destination File (FullPath)
    'FailIfDestExists (Optional):
    'Set to true if you don't want to
    'overwrite the destination file if
    'it exists

    'Returns (True if Successful, false otherwise)

    'EXAMPLE:
    'dim bSuccess as boolean
    'bSuccess = APIFileCopy ("C:\MyFile.txt", "D:\MyFile.txt")

    Dim lRet As Long
    lRet = CopyFile(src, dest, FailIfDestExists)
    APIFileCopy = (lRet > 0)
    End Function

    Hope this helps.

    "G3£Wh)zZ@" wrote:

    > Cat walked over keyboard and actually sent the previous post uncomplete so
    > here it is complete..thansk for reading.
    >
    > I have a lot of files on cd/dvd that i am moving into one folder on my hdd
    > so i can sort them out before reburning them. However there are quiet a few
    > mp3 files that have the same name etc but because i converted these at a
    > higher bit rate they are larger in size, whilst moving them to the folder i
    > keep getting the "would i like to replace the existing file" and have to
    > click either yes or no.
    >
    > Its a pain ...so is there anything out there or anything i can do , that
    > will only copy/replace the original file if the new file is larger in size..
    >
    >
    > --
    > The Source For Premium Newsgroup Access
    > Great Speed, Great Retention
    > 1 GB/Day for only $8.95
    >


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1