?
Solved

when i copy something in a worksheet excel closes down.

Posted on 2003-03-26
9
Medium Priority
?
677 Views
Last Modified: 2012-08-14
hi, ive got a problem with excel.
when i press copy and paste on a worksheet with macros on it. the illegal operation box pops up and then closes excel down.
all other macros work on worksheet apart from ones involving copy.

if i make another worksheet with copy on it in a seperate workbook it works fine.

do u guys have any idea on whats wrong?
thanks in advance, stav.
i have windows 98
and excel 2000.
0
Comment
Question by:stavstav
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
9 Comments
 
LVL 81

Expert Comment

by:byundt
ID: 8215721
Are you using macros to drive the copy and paste? If so, did they used to work correctly? If not, then you may have a syntax problem. If so, those macros won't work in any other workbook. If that's the case, please post the relevant part of the macro.

Is the problem repeatable in other machines? If not, you may need to reinstall Excel.

Is the problem repeatable in different versions of Excel? Macros that used to work in older versions of Excel sometimes work differently because Microsoft changes VBA.

If the problem is repeatable in other machines and versions of Excel, then you may have corruption in your file. http://support.microsoft.com/default.aspx?scid=kb;en-us;179871 describes how to recover the data from a corrupted file in Excel 2000.

0
 

Expert Comment

by:T-y
ID: 8219319
It could be that another program or macro has triggered this.

Go to Tools ->Macro -> Macros and check that you don't have one that is causing it, I have had this exact problem in Word 2000 and the user had some obscure macro's from goodness knows where.  


Cheers

T-y
0
 

Author Comment

by:stavstav
ID: 8220015
i am using macros to drive the copy and paste and yes they used to work. but now even if i dont use the macro to copy and paste it still does it and yes it also does it on other comps.
if i open i new workbook i can copy and paste as muchg as i like. even if i disable macros before opening the file and then press copy, it will still cause an illegal operation.
i also saved the file into 97 format to open at college and the same thing happens...illegal op.
i also tried that link u gave and but i dont have some of the features mentioned. if i try saving it as html it says illegal op half way thru.
plus when i ran another copy paste macro on another heet in the same workbook this message came up:

the top bit said " microsoft visual basic"

SYSTEM ERROR &H80010108(-2147417848)
THE OBJECT INVOKED HAS DISCONNECTED FROM ITS CLIENTS.


heres the code if u want to see it.:
Sub Addstore()


      Range("A8").Select
    Selection.CurrentRegion.Select
    Selection.End(xlDown).Select
    ActiveCell.Offset(1, 0).Range("A1").Select
    Range("G4").Select
    Selection.Copy
    Range("A8").Select
    Selection.CurrentRegion.Select
    Selection.End(xlDown).Select
    ActiveCell.Offset(1, 0).Range("A1").Select
    ActiveSheet.Paste
    Range("B4").Select
    Application.CutCopyMode = False
    Selection.Copy
    Range("A8").Select
    Selection.CurrentRegion.Select
    Selection.End(xlDown).Select
    ActiveCell.Offset(0, 1).Range("A1").Select
    ActiveSheet.Paste
    Range("D4").Select
    Application.CutCopyMode = False
    Selection.Copy
    Range("A8").Select
    Selection.CurrentRegion.Select
    Selection.End(xlDown).Select
    ActiveCell.Offset(0, 2).Range("A1").Select
    ActiveSheet.Paste
    Range("F4").Select
    Application.CutCopyMode = False
    Selection.Copy
    Range("A8").Select
    Selection.CurrentRegion.Select
    Selection.End(xlDown).Select
    ActiveCell.Offset(0, 3).Range("A1").Select
    ActiveSheet.Paste
    Application.CutCopyMode = False
    Range("A8").Select

End Sub

T.y. i dont have another other macros in there aprt from the ones i need.

cheers, Stav.
0
Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

 

Author Comment

by:stavstav
ID: 8220036
one other thing i forgot to mention i started seperate sections of the workbook as other workbooks and then copied them all into one. i.e. worksheets in workooks a & b are now in all in workbook b.
0
 

Expert Comment

by:T-y
ID: 8223680
Why don't you recreate the blank default excel workbook (its just like replacing the normal.dot in word) and recreate the macro and see if that works.  Now can I remember how to do that, right I know that the ext for the default workbook is xlt.  I'm also sure that the default one is book.xlt, there is also a default sheet.xlt

I think that all is necessary is like in word where you just delete them, I think they get recreated automatically, but maybe someone else can confirm that.

Cheers

T-y
0
 

Author Comment

by:stavstav
ID: 8238208
what do i do? sorry mate i didnt get that lol.
do i just delete the extension?
0
 

Accepted Solution

by:
T-y earned 80 total points
ID: 8238310
Sorry should have been clearer

Search for the 2 files sheet.xlt and book.xlt and delete them, then run a repair on office.

Also you could try loading the latest office service pack.

Also just found this article which has the same error code as your message (might have nothing to do with it but you never know):-

http://support.microsoft.com/default.aspx?scid=kb;en-us;318218



0
 
LVL 11

Expert Comment

by:turn123
ID: 10108315
stavstav,
No comment has been added lately (288 days), so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area for this question:

RECOMMENDATION: Award points to T-y http:#8238310

Please leave any comments here within 7 days.

-- Please DO NOT accept this comment as an answer ! --

Thanks,

turn123
EE Cleanup Volunteer
0

Featured Post

U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Healthcare organizations in the United States must adhere to the guidance of both the HIPAA (Health Insurance Portability and Accountability Act) and HITECH (Health Information Technology for Economic and Clinical Health Act) for securing and protec…
In this article, you will read about the trends across the human resources departments for the upcoming year. Some of them include improving employee experience, adopting new technologies, using HR software to its full extent, and integrating artifi…
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question