LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default why this code doesn't work?

Dear friends
Someone can tell me why the code "wkbk.Close SaveChange:=False doesn'
work" in the macro below?
Is it possible to write the bklist in a different way (more short)?
Thanks in advance

Sub Unisce_file()
bkList = Array("C:\Documents an
Settings\donello\Desktop\MACRO\vendite.xls", _
"C:\Documents and Settings\donello\Desktop\MACRO\ordini.xls", _
"C:\Documents and Settings\donello\Desktop\MACRO\bdg.xls", _
"C:\Documents and Settings\donello\Desktop\MACRO\personale.xls", _
"C:\Documents and Settings\donello\Desktop\MACRO\mdc.xls")
For i = LBound(bkList) To UBound(bkList)
Set wkbk = Workbooks.Open(bkList(i))
If i = LBound(bkList) Then
wkbk.Sheets.Copy
Set wkbk1 = ActiveWorkbook
Else
wkbk.Sheets.Copy After:=wkbk1.Sheets(wkbk1.Sheets.Count)
End If
Next
wkbk1.SaveAs Filename:="C:\Documents an
Settings\donello\Desktop\MACRO\report.xls"
wkbk.Close SaveChange:=False
End Su

--
Message posted from http://www.ExcelForum.com

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why does this code not work? rk0909 Excel Discussion (Misc queries) 12 September 4th 08 10:42 PM
Why this code is not work? Error code when select worksheet Excel Worksheet Functions 4 December 4th 07 12:51 AM
Code won't work? Joe 90 Excel Programming 3 October 2nd 03 04:26 AM
Why my code do not work : - ( Tom Ogilvy Excel Programming 1 August 31st 03 04:53 PM
Why my code do not work : - ( Bob Phillips[_5_] Excel Programming 0 August 31st 03 01:27 PM


All times are GMT +1. The time now is 03:05 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"