Re: $$Excel-Macros$$ Copy files in folder except one file

2011-01-06 Thread Paul Schreiner
From: Nasim nbeiz...@gmail.com To: MS EXCEL AND VBA MACROS excel-macros@googlegroups.com Sent: Wed, January 5, 2011 11:41:10 PM Subject: $$Excel-Macros$$ Copy files in folder except one file Hi, I need to combine several excel files into one file. I create this new file in the directory

Re: $$Excel-Macros$$ Copy files in folder except one file

2011-01-06 Thread Nasim
EXCEL AND VBA MACROS excel-macros@googlegroups.com Sent: Wed, January 5, 2011 11:41:10 PM Subject: $$Excel-Macros$$ Copy files in folder except one file Hi, I need to combine several excel files into one file. I create this new file in the directory that user chooses (this folder contains

Re: $$Excel-Macros$$ Copy files in folder except one file

2011-01-06 Thread Nasim
Thanks Ashish. I did what you recommended and it considers the if result to be true so goes through the all lines. I added watch for excelFile and it shows me Combined Manual Timesheet.xls at the bottom of the page. I am not sure why it does not recognize that in the if statement. Thanks, Nasim

Re: $$Excel-Macros$$ Copy files in folder except one file

2011-01-06 Thread Nasim
to finish before all files are processed. Paul From: Nasim nbeiz...@gmail.com To: MS EXCEL AND VBA MACROS excel-macros@googlegroups.com Sent: Wed, January 5, 2011 11:41:10 PM Subject: $$Excel-Macros$$ Copy files in folder except one file Hi, I need

$$Excel-Macros$$ Copy files in folder except one file

2011-01-05 Thread Nasim
Hi, I need to combine several excel files into one file. I create this new file in the directory that user chooses (this folder contains the files I want to copy). It loops trough the files and works perfectly except that it copies the combined Manual Timesheets.xls file and pastes it to itself

Re: $$Excel-Macros$$ Copy files in folder except one file

2011-01-05 Thread ashish koul
try this it may help Fpath = BrowseFolder(Caption:=Select the folder .) excelFile = Dir(Fpath \*.xls) Do While excelFile If excelFile Combined Manual Timesheets.xls Then Workbooks.Open Filename:=Fpath \ excelFile ' copy rows ActiveWorkbook.Sheets(1).Activate LastRow