I do not think you want me to post all code I ran becasue it is over 1000
lines.
Here I post my code plus your suggested code.
I have a stop right at your first DIM code and check the contents in the
'Consumer Adjustments 2005.xls' which was fine at the points. When the
process is completed, I can see my file is there. However sometimes I
cannot open it because it tells me it is locked and used by me. I click it,
it open up with Book1.xls with Sheet1, Sheet2, Sheet3 and Sheet4. Why it
turned out to be Book1.xls not my file. The last posting I made I did not
notice this fact. All I saw was 4 sheets.
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel97, "Consumer",
(Path & "Consumer Adjustment 2005.xls"), False
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel97, VpName(2),
(Path & "Consumer Adjustment 2005.xls"), False
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel97, VpName(5),
(Path & "Consumer Adjustment 2005.xls"), False
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel97, VpName(4),
(Path & "Consumer Adjustment 2005.xls"), False
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel97, VpName(3),
(Path & "Consumer Adjustment 2005.xls"), False
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel97, VpName(1),
(Path & "Consumer Adjustment 2005.xls"), False
'----------------------------
'Path = "C:\Documents and Settings\V344053\My Documents\Consumer\"
Dim strWorkbook As String
Dim strWorksheet As String
Dim oxlBook As Excel.Workbook
Dim oxlSheet As Excel.Worksheet
'strWorkbook = "C:\Folder\File.xls"
'strQuery = "MyQuery"
'DoCmd.TransferSpreadsheet acExport, , strQuery, strWorkbook
'Open workbook
Set oxlBook = GetObject(Path & "Consumer Adjustment 2005.xls")
Set oxlSheet = oxlBook.Worksheets("Consumer")
'Delete row
oxlSheet.Rows(1).Delete
oxlBook.Save 'Save workbook
oxlBook.Parent.Quit 'Close Excel
Tsoying,