Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default Large macro "drops out" part way through

Hello All,

I've got a difficult problem to analyse.
My program opens many workbooks (~40) one at a time then moves data
into each; does a refresh; and then saves the workbook. This all
happens in a second instance of Excel.

Problem is that it has started to just stop half way through with no
error message - I'll activate the instance of excel and one of the
mentioned workbooks will be open in design mode....with no clue as to
why!!

It takes about 25mins all in so stopping after 15mins of success is a
pain.

(Sometimes I can re-run and all will go through ok)

Anybody got any ideas, or experienced anything like this before?

Any help much appreciated
Jason
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 48
Default Large macro "drops out" part way through

Difficult to diagnose without seeing it but here are some things to
try...

1) set Application.EnableEvents = False before allowing your app to
open any other workbooks.
2) If you're copying sheets into a workbook you may be hitting a
limit. Excel doesn't specify a number for this limit but it is
dependant on available resources and quantity of data in the sheets
being copied (I think). Excel will give a run-time error '1004':
Method of object '_Worksheet' failed.
The work-around for this is to have the macro Save and Close the
workbook after a certain number of sheets copied in. Then have it re-
open the workbook and carry on where it left off.
3) You say your NOT getting an error so make sure any error handling
within your routines - such as On Error Resume Next - is turned off so
that you're not disguising the problem.

Br, Nick H
  #3   Report Post  
Posted to microsoft.public.excel.programming
jaf jaf is offline
external usenet poster
 
Posts: 300
Default Large macro "drops out" part way through

Hi Jason,
Are the files located on another machine? A server maybe?
Adding a "DOEVENTS" between files should take care of any network timing issues.

John


wrote in message ...
Hello All,

I've got a difficult problem to analyse.
My program opens many workbooks (~40) one at a time then moves data
into each; does a refresh; and then saves the workbook. This all
happens in a second instance of Excel.

Problem is that it has started to just stop half way through with no
error message - I'll activate the instance of excel and one of the
mentioned workbooks will be open in design mode....with no clue as to
why!!

It takes about 25mins all in so stopping after 15mins of success is a
pain.

(Sometimes I can re-run and all will go through ok)

Anybody got any ideas, or experienced anything like this before?

Any help much appreciated
Jason

Reply
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
Using the functions "LARGE"and "SMALL" in an Excel program Ed[_30_] Excel Programming 0 March 18th 08 05:14 PM
Mail Merge drops 1st digit ("0") converting from Excel to Word Chuck Martini Excel Discussion (Misc queries) 3 August 7th 06 10:34 PM
Utility to "clean up" or "defrag" large Excel file Sabrina Excel Discussion (Misc queries) 3 January 12th 06 09:57 PM
.csv drops "0" when saved, even if file was set as "text". TRminator Excel Discussion (Misc queries) 3 November 2nd 05 02:11 PM
Leftmost part of screen "blued" out when calculating via a macro nurkus[_2_] Excel Programming 4 May 17th 05 06:36 AM


All times are GMT +1. The time now is 04:36 PM.

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

About Us

"It's about Microsoft Excel"