View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
jim sturtz jim sturtz is offline
external usenet poster
 
Posts: 11
Default automation autosave .xls as .txt

i have the code below for foxpro that will load an .xls and show it on the
desktop.

i would like it to merely load the .xls and do an autosave as a .txt file
type, as the file i am starting with has lots of dross in it that can easily
be removed by saving as a .txt

i think if i change the loExcel.Visible=.t. to .f. then i wouldnt see the
file, so what commands would do the autosave and then autoexit?

thanks.

jim

*****
Local loExcel As Excel.Application
Local loWorkBook As Excel.Workbook
Local loActiveSheet As Excel.Sheets
Local loRange As Excel.Range
Local lError, lcFileName
lError = .F.

Try

loExcel = Createobject("Excel.Application")

F2L=Fullpath(F2L)
lcFileName=F2L && this is the file opened


loWorkBook = loExcel.Workbooks.Open(lcFileName)
loActiveSheet = loExcel.ActiveSheet
loExcel.Visible=.T.
*****


microsoft.public.excel.worksheet.functions