Re: saveas without prompt

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



On Sep 17, 7:15 am, "Olaf Doschke"
<b2xhZi5kb3NjaGtlQHNldG1pY3Mu...@xxxxxxxxxxxxx> wrote:
#DEFINE xlLocalSessionChanges 2

oExcel.DisplayAlerts = .F.
oExcel.ActiveWorkbook.SaveAs("Filename.xls",,,,,,,xlLocalSessionChanges)

I'm not sure if you can skip all other paramters this way,
but DisplayAlerts is more important, xlLocalSessionChanges
may only be important if you opened a file, worked on
it and save() changes (not saveAS). But it may also be
needed to actually overwrite the file additional to suppressing
the alert.

Another way would be to ERASE the file from VFP,
before you save from excel. If that file is open in another
Excel session, you'll have a problem anyway.

I tend to solve such conflicts by adding a timestamp
to the filename if the pure file name already exists.

Bye, Olaf.

Hey Olaf,
If you don't mind would you tell me how you "add a timestamp" to a
filename?
Thank you,
john3
.



Relevant Pages

  • Re: saveas without prompt
    ... lcFilename = ForceExt+ ... Excel session, ... I tend to solve such conflicts by adding a timestamp ... to the filename if the pure file name already exists. ...
    (microsoft.public.fox.programmer.exchange)
  • Re: Creating a file with timestamp
    ... > timestamp that there is no way for this (the filename) to actually be ... If you are creating a filename based on a timestamp, ... I have a shell script that chooses the lowest ... that you wouldn't be creating multiple files with the same ...
    (comp.os.linux.misc)
  • [ANN] called_from 0.1.0 released
    ... which gets filename and line number of caller. ... ## if cache data is older than template file's timestamp, ... $ ruby setup.rb config ...
    (comp.lang.ruby)
  • Re: time(NULL) returning wrong month???
    ... im writing a logging utility the log files created will contain 14byte ... are its timestamp, that is the # of seconds ... last is the date string i use to create the filename with (filename ...
    (comp.unix.programmer)
  • time(NULL) returning wrong month???
    ... im writing a logging utility the log files created will contain 14byte ... are its timestamp, that is the # of seconds ... last is the date string i use to create the filename with (filename ... GetFDate to write the filename date string. ...
    (comp.unix.programmer)