View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
ugoveri ugoveri is offline
external usenet poster
 
Posts: 5
Default Excel 2007 problem with macros

I was somewhat a little wrong...

Opening Excel 2003 version in 2007 opens fine, but if I try to apply the
macro, apparently I get errors...

I had a line object with a macro assigned that copied a sheet to another
copying simultaneously some values from the previous sheet to the new one...
It also checks for existing names, and if the new name exist it stops,
otherwise it renames with then new sequential name...

I also had the combo box that had a macro attached that renamed the sheet
manually... Basically this to make my accountant monthly work...

When copying the data to the new sheet it copies the sheet to a new one...
It doesn't copy the combo box, and the line objects are copied out of it's
previous place or not copied at all...

After this if click the macro to copy again to a new sheet it shows the
following error:

Run-time error '-2147417848 (80010108)':

Automation error. The object invoked has disconnected from its clients.

If I click debug it points me:

Sub NovaFolha()
Application.ScreenUpdating = False
Application.Calculation = xlCalculationManual
Dim array_aux() As Variant
ActiveSheet.Activate
a = ActiveSheet.Name
B = Range("f4")
= Sheets(a).Copy After:=Sheets(a) --- This is the line selected by
debug...