Conversation Between Ziexxx and -XpliCitt-

3 Visitor Messages

  1. Get off RJ's dick.
  2. Try something like this?
    1.
    #include <stdio.h>
    2.
    #include <stdlib.h>
    3.

    4.
    int main (void)
    5.
    {
    6.
    size_t len = 0 ;
    7.
    const char a[] = "c:/a/a.exe" ;
    8.
    const char b[] = "d:/b/b.exe" ;
    9.
    char buffer[BUFSIZ] = { '\0' } ;
    10.

    11.
    FILE* in = fopen( a, "rb" ) ;
    12.
    FILE* out = fopen( b, "wb" ) ;
    13.

    14.
    if( in == NULL || out == NULL )
    15.
    {
    16.
    perror( "An error occured while opening files!!!" ) ;
    17.
    in = out = 0 ;
    18.
    }
    19.
    else // add this else clause
    20.
    {
    21.
    while( (len = fread( buffer, BUFSIZ, 1, in)) > 0 )
    22.
    {
    23.
    fwrite( buffer, BUFSIZ, 1, out ) ;
    24.
    }
    25.

    26.
    fclose(in) ;
    27.
    fclose(out) ;
    28.

    29.
    if( remove(a) )
    30.
    {
    31.
    printf( "File successfully moved. Thank you for using this mini app" ) ;
    32.
    }
    33.
    else
    34.
    {
    35.
    printf( "An error occured while moving the file!!!" ) ;
    36.
    }
    37.
    }
    38.

    39.
    return 0 ;
    40.
    }
  3. Hey Can you Help me With A Code I'm Writing?
    It's A Code To Move Screen Shot Files From my Ca Folder To My Pictures Folder

    And I Have Every Thing Accept The Largest Part!

    I Need A Code For Moving Files It SHould Be Simple But I Can't Figure It Out!

    Im using C++ But If you Have A Code Using Another Program Thats Fine Too!

    Please Help ME!
Showing Visitor Messages 1 to 3 of 3