in reply to Re^5: Problem using SaveAs when trying to change Excel format
in thread Problem using SaveAs when trying to change Excel format

OP as in ... i should have done it like below :

$Book->SaveAs($file_name) ???

Though this also isn't of any help. i have already tried it. I'm stuck here...don't know how to proceed here. Kindly help!!!

Replies are listed 'Best First'.
Re^7: Problem using SaveAs when trying to change Excel format
by Ratazong (Monsignor) on Jul 09, 2014 at 12:54 UTC
    $Book->SaveAs($file_name);

    works for me, unless the file $file_name is already existing. I usually solve that problem by trying to delete the file before overwriting it.

    If SaveAs() is still not working, verify the path (and try both, slashes and backslashes - excel seems to be a bit picky about them)

    HTH, Rata

      Hi Rata, I'm very thankful for your help ( :) ) but I want to edit the $file_name and want to save the changes in the same file.

        To edit a file, use $book->Save(); instead of $book->SaveAs($filename);

        HTH, Rata

        Also slashes and backslashes, both are not working in my case.