ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Excel won't copy outside sheet (https://www.excelbanter.com/excel-discussion-misc-queries/26351-excel-wont-copy-outside-sheet.html)

Jack Sons

Excel won't copy outside sheet
 
Hi all,

I've got a severe problem. My Excel 2000 (with XP sp2) wil no longer copy
anything to another sheet of the workbook or another workbook.

I start Excel, open a new workbooks and type in a cel e.g. "aaa" (without
the ") and enter. All looks normal. If I click on that cell then with ctr C
and crt V (or with the copy buttons) I can copy its content to any other
cell on the same worksheet, but not to another sheet of the same workbook,
let alone another workbook. In that case I get no error message but only a
"plong"sound when I do ctr V. After that the copy in memory appears to be
erased because ctr V on the original sheet does not a thing anymore. I
noticed that after ctr C as soon as I hit enter the copy possibility is
gone, because I see that the corresponding copy buttons at once are grayed
out. That happens even right after ctr C when I hit the enter key. The gray
out occurs also as soon as I hit the tab of another sheet or switch to
another workbook.

Another strange thing is that when after ctr C I click another cell on the
same sheet and hit enter the same occurs as after ctr V, aaa is copied! As I
said, if I hit enter before I take the cursor (mouse pointer) away from the
original cell the copying process is aborted.

I tried to overcome this by going back to a system repair point (don't know
the proper English name) of almost three weeks ago - when the problems did
not yet occur - but to no avail.

I am in urgent need of help. Your advice will be appreciated.

Jack Sons
The Netherlands



David McRitchie

I can't spot the problem but take a look at
Grayed Out Options
http://www.mvps.org/dmcritchie/excel/grayedout.htm

check if the sheet or workbook is protected,
may change copying of formulas to values instead

Make sure you don't have any search going on
file search, text search in files, Outlook Express search
they don't gray out the buttons but you do get invalid results
Sometimes the menus work better for these than the shortcut keys.

Try opening workbook without macros. Check ThisWorkbook for
macros. (right click on Excel logo left of menu bar, view code)

Have you been through a reboot.

I've had strange things happen with a stuck Ctrl key, but I can't
see how any key would cause what you describe.

---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Jack Sons" wrote in message ...
Hi all,

I've got a severe problem. My Excel 2000 (with XP sp2) wil no longer copy
anything to another sheet of the workbook or another workbook.

I start Excel, open a new workbooks and type in a cel e.g. "aaa" (without
the ") and enter. All looks normal. If I click on that cell then with ctr C
and crt V (or with the copy buttons) I can copy its content to any other
cell on the same worksheet, but not to another sheet of the same workbook,
let alone another workbook. In that case I get no error message but only a
"plong"sound when I do ctr V. After that the copy in memory appears to be
erased because ctr V on the original sheet does not a thing anymore. I
noticed that after ctr C as soon as I hit enter the copy possibility is
gone, because I see that the corresponding copy buttons at once are grayed
out. That happens even right after ctr C when I hit the enter key. The gray
out occurs also as soon as I hit the tab of another sheet or switch to
another workbook.

Another strange thing is that when after ctr C I click another cell on the
same sheet and hit enter the same occurs as after ctr V, aaa is copied! As I
said, if I hit enter before I take the cursor (mouse pointer) away from the
original cell the copying process is aborted.

I tried to overcome this by going back to a system repair point (don't know
the proper English name) of almost three weeks ago - when the problems did
not yet occur - but to no avail.

I am in urgent need of help. Your advice will be appreciated.

Jack Sons
The Netherlands





Jack Sons

David,

I already rebooted a hundred times in the last days.
I checked already (of course) that no sheet or book was protected.
I also was afraid of ongoing searches myself and already tried to see if a
search was running but could not detect any.
I checked also the the ThisWorkbook module of the only open workbook, it (of
course) contained no macros, how could it have macros.

Your explicit questions made me think further (thank you for that), at once
it struck me that hidden files were also open, like personal.xls and my
book.xlt, both in my XLSTART. In book.xlt I put macros (see below the dotted
line at the end of this email) I recently got from Dave Peterson. The
purpose of these macros was to ensure that every newly opened sheet of an
existing workbook and every sheet of a newly opened wokbook would have the
option "display zeros" checked out. For some misterious reason I always have
zeros representated on new sheets and new workbooks, so every time I have to
go to toolsoptionsa tab in English maybe called view (I use the Dutch
version) and then have to uncheck the option about visible zeros, I mean the
middle checkbox of the lowest line of checkboxes. It is so annoying that I
was glad to have these macros.

When I got rid of book.xlt or made the macros inactive by putting ' before
each line my problem was over.

To my regret I can't see why these macros cuased my trouble, it seems they
contain no search actions or any other code that prevents copying to any
onther sheet. Could you please explain? Also, could you augment these macros
so that they ensure that the zeros option is checked out but without causing
other troubles? If that is not possible, is there any problemless method to
get rid automatically (bij default) of zeros in spreadsheets?

I am looking forward to your explanation and your advice. Up to now it was
already invaluable to me, I am quite relieved, a thouthand thanks.

Jack.
---------------------------------------------------------------------------------
'Option Explicit
'Public WithEvents xlApp As Application
'Private Sub Workbook_BeforeClose(Cancel As Boolean)
' Set xlApp = Nothing
'End Sub
'Private Sub Workbook_Open()
' Set xlApp = Application
'End Sub
'Private Sub xlApp_SheetActivate(ByVal Sh As Object)
' ActiveWindow.DisplayZeros = False
'End Sub
'Private Sub xlApp_WorkbookActivate(ByVal Wb As Workbook)
' ActiveWindow.DisplayZeros = False
'End Sub

"David McRitchie" schreef in bericht
...
I can't spot the problem but take a look at
Grayed Out Options
http://www.mvps.org/dmcritchie/excel/grayedout.htm

check if the sheet or workbook is protected,
may change copying of formulas to values instead

Make sure you don't have any search going on
file search, text search in files, Outlook Express search
they don't gray out the buttons but you do get invalid results
Sometimes the menus work better for these than the shortcut keys.

Try opening workbook without macros. Check ThisWorkbook for
macros. (right click on Excel logo left of menu bar, view code)

Have you been through a reboot.

I've had strange things happen with a stuck Ctrl key, but I can't
see how any key would cause what you describe.

---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Jack Sons" wrote in message
...
Hi all,

I've got a severe problem. My Excel 2000 (with XP sp2) wil no longer copy
anything to another sheet of the workbook or another workbook.

I start Excel, open a new workbooks and type in a cel e.g. "aaa"
(without
the ") and enter. All looks normal. If I click on that cell then with ctr
C
and crt V (or with the copy buttons) I can copy its content to any other
cell on the same worksheet, but not to another sheet of the same
workbook,
let alone another workbook. In that case I get no error message but only
a
"plong"sound when I do ctr V. After that the copy in memory appears to be
erased because ctr V on the original sheet does not a thing anymore. I
noticed that after ctr C as soon as I hit enter the copy possibility is
gone, because I see that the corresponding copy buttons at once are
grayed
out. That happens even right after ctr C when I hit the enter key. The
gray
out occurs also as soon as I hit the tab of another sheet or switch to
another workbook.

Another strange thing is that when after ctr C I click another cell on
the
same sheet and hit enter the same occurs as after ctr V, aaa is copied!
As I
said, if I hit enter before I take the cursor (mouse pointer) away from
the
original cell the copying process is aborted.

I tried to overcome this by going back to a system repair point (don't
know
the proper English name) of almost three weeks ago - when the problems
did
not yet occur - but to no avail.

I am in urgent need of help. Your advice will be appreciated.

Jack Sons
The Netherlands







Dave Peterson

First, lots of macros destry the cutcopymode status. It sounds like the
application event that runs each time you activate a different sheet is doing
it.

So you have a choice to make. Keep the macro and live with the copy|paste
problem or kill the macro and bring back the copy|paste abilility. I don't
think that there's any other way around it.

And secondly, the macro you pasted shouldn't be in book.xlt. It should be in
personal.xls.

===

Another option (maybe it'll be sufficient for you).

Move that code out of personal.xls (assuming you've already removed it from
book.xlt).

Put the code in a nice dedicated workbook in your addin folder.

Then you can install the addin via Tools|Addins.

If you want to turn it off, just uncheck it in tools|addins. (Toggle it back on
when you absolutely need it.)

===
I still would have had a dedicated macro that would run on demand!

Jack Sons wrote:

David,

I already rebooted a hundred times in the last days.
I checked already (of course) that no sheet or book was protected.
I also was afraid of ongoing searches myself and already tried to see if a
search was running but could not detect any.
I checked also the the ThisWorkbook module of the only open workbook, it (of
course) contained no macros, how could it have macros.

Your explicit questions made me think further (thank you for that), at once
it struck me that hidden files were also open, like personal.xls and my
book.xlt, both in my XLSTART. In book.xlt I put macros (see below the dotted
line at the end of this email) I recently got from Dave Peterson. The
purpose of these macros was to ensure that every newly opened sheet of an
existing workbook and every sheet of a newly opened wokbook would have the
option "display zeros" checked out. For some misterious reason I always have
zeros representated on new sheets and new workbooks, so every time I have to
go to toolsoptionsa tab in English maybe called view (I use the Dutch
version) and then have to uncheck the option about visible zeros, I mean the
middle checkbox of the lowest line of checkboxes. It is so annoying that I
was glad to have these macros.

When I got rid of book.xlt or made the macros inactive by putting ' before
each line my problem was over.

To my regret I can't see why these macros cuased my trouble, it seems they
contain no search actions or any other code that prevents copying to any
onther sheet. Could you please explain? Also, could you augment these macros
so that they ensure that the zeros option is checked out but without causing
other troubles? If that is not possible, is there any problemless method to
get rid automatically (bij default) of zeros in spreadsheets?

I am looking forward to your explanation and your advice. Up to now it was
already invaluable to me, I am quite relieved, a thouthand thanks.

Jack.
---------------------------------------------------------------------------------
'Option Explicit
'Public WithEvents xlApp As Application
'Private Sub Workbook_BeforeClose(Cancel As Boolean)
' Set xlApp = Nothing
'End Sub
'Private Sub Workbook_Open()
' Set xlApp = Application
'End Sub
'Private Sub xlApp_SheetActivate(ByVal Sh As Object)
' ActiveWindow.DisplayZeros = False
'End Sub
'Private Sub xlApp_WorkbookActivate(ByVal Wb As Workbook)
' ActiveWindow.DisplayZeros = False
'End Sub

"David McRitchie" schreef in bericht
...
I can't spot the problem but take a look at
Grayed Out Options
http://www.mvps.org/dmcritchie/excel/grayedout.htm

check if the sheet or workbook is protected,
may change copying of formulas to values instead

Make sure you don't have any search going on
file search, text search in files, Outlook Express search
they don't gray out the buttons but you do get invalid results
Sometimes the menus work better for these than the shortcut keys.

Try opening workbook without macros. Check ThisWorkbook for
macros. (right click on Excel logo left of menu bar, view code)

Have you been through a reboot.

I've had strange things happen with a stuck Ctrl key, but I can't
see how any key would cause what you describe.

---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Jack Sons" wrote in message
...
Hi all,

I've got a severe problem. My Excel 2000 (with XP sp2) wil no longer copy
anything to another sheet of the workbook or another workbook.

I start Excel, open a new workbooks and type in a cel e.g. "aaa"
(without
the ") and enter. All looks normal. If I click on that cell then with ctr
C
and crt V (or with the copy buttons) I can copy its content to any other
cell on the same worksheet, but not to another sheet of the same
workbook,
let alone another workbook. In that case I get no error message but only
a
"plong"sound when I do ctr V. After that the copy in memory appears to be
erased because ctr V on the original sheet does not a thing anymore. I
noticed that after ctr C as soon as I hit enter the copy possibility is
gone, because I see that the corresponding copy buttons at once are
grayed
out. That happens even right after ctr C when I hit the enter key. The
gray
out occurs also as soon as I hit the tab of another sheet or switch to
another workbook.

Another strange thing is that when after ctr C I click another cell on
the
same sheet and hit enter the same occurs as after ctr V, aaa is copied!
As I
said, if I hit enter before I take the cursor (mouse pointer) away from
the
original cell the copying process is aborted.

I tried to overcome this by going back to a system repair point (don't
know
the proper English name) of almost three weeks ago - when the problems
did
not yet occur - but to no avail.

I am in urgent need of help. Your advice will be appreciated.

Jack Sons
The Netherlands





--

Dave Peterson

Jack Sons

Dave,

Thanks for all your advice. I already removed book.xlt. I will try the addin
way.

Put the code in a nice dedicated workbook in your addin folder.

Do I have to call it book.xla?

First, lots of macros destroy the cutcopymode status.

But what line in the removed code caused it?

Jack.


"Dave Peterson" schreef in bericht
...
First, lots of macros destry the cutcopymode status. It sounds like the
application event that runs each time you activate a different sheet is
doing
it.

So you have a choice to make. Keep the macro and live with the copy|paste
problem or kill the macro and bring back the copy|paste abilility. I
don't
think that there's any other way around it.

And secondly, the macro you pasted shouldn't be in book.xlt. It should be
in
personal.xls.

===

Another option (maybe it'll be sufficient for you).

Move that code out of personal.xls (assuming you've already removed it
from
book.xlt).

Put the code in a nice dedicated workbook in your addin folder.

Then you can install the addin via Tools|Addins.

If you want to turn it off, just uncheck it in tools|addins. (Toggle it
back on
when you absolutely need it.)

===
I still would have had a dedicated macro that would run on demand!

Jack Sons wrote:

David,

I already rebooted a hundred times in the last days.
I checked already (of course) that no sheet or book was protected.
I also was afraid of ongoing searches myself and already tried to see if
a
search was running but could not detect any.
I checked also the the ThisWorkbook module of the only open workbook, it
(of
course) contained no macros, how could it have macros.

Your explicit questions made me think further (thank you for that), at
once
it struck me that hidden files were also open, like personal.xls and my
book.xlt, both in my XLSTART. In book.xlt I put macros (see below the
dotted
line at the end of this email) I recently got from Dave Peterson. The
purpose of these macros was to ensure that every newly opened sheet of an
existing workbook and every sheet of a newly opened wokbook would have
the
option "display zeros" checked out. For some misterious reason I always
have
zeros representated on new sheets and new workbooks, so every time I have
to
go to toolsoptionsa tab in English maybe called view (I use the Dutch
version) and then have to uncheck the option about visible zeros, I mean
the
middle checkbox of the lowest line of checkboxes. It is so annoying that
I
was glad to have these macros.

When I got rid of book.xlt or made the macros inactive by putting '
before
each line my problem was over.

To my regret I can't see why these macros cuased my trouble, it seems
they
contain no search actions or any other code that prevents copying to any
onther sheet. Could you please explain? Also, could you augment these
macros
so that they ensure that the zeros option is checked out but without
causing
other troubles? If that is not possible, is there any problemless method
to
get rid automatically (bij default) of zeros in spreadsheets?

I am looking forward to your explanation and your advice. Up to now it
was
already invaluable to me, I am quite relieved, a thouthand thanks.

Jack.
---------------------------------------------------------------------------------
'Option Explicit
'Public WithEvents xlApp As Application
'Private Sub Workbook_BeforeClose(Cancel As Boolean)
' Set xlApp = Nothing
'End Sub
'Private Sub Workbook_Open()
' Set xlApp = Application
'End Sub
'Private Sub xlApp_SheetActivate(ByVal Sh As Object)
' ActiveWindow.DisplayZeros = False
'End Sub
'Private Sub xlApp_WorkbookActivate(ByVal Wb As Workbook)
' ActiveWindow.DisplayZeros = False
'End Sub

"David McRitchie" schreef in bericht
...
I can't spot the problem but take a look at
Grayed Out Options
http://www.mvps.org/dmcritchie/excel/grayedout.htm

check if the sheet or workbook is protected,
may change copying of formulas to values instead

Make sure you don't have any search going on
file search, text search in files, Outlook Express search
they don't gray out the buttons but you do get invalid results
Sometimes the menus work better for these than the shortcut keys.

Try opening workbook without macros. Check ThisWorkbook for
macros. (right click on Excel logo left of menu bar, view code)

Have you been through a reboot.

I've had strange things happen with a stuck Ctrl key, but I can't
see how any key would cause what you describe.

---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Jack Sons" wrote in message
...
Hi all,

I've got a severe problem. My Excel 2000 (with XP sp2) wil no longer
copy
anything to another sheet of the workbook or another workbook.

I start Excel, open a new workbooks and type in a cel e.g. "aaa"
(without
the ") and enter. All looks normal. If I click on that cell then with
ctr
C
and crt V (or with the copy buttons) I can copy its content to any
other
cell on the same worksheet, but not to another sheet of the same
workbook,
let alone another workbook. In that case I get no error message but
only
a
"plong"sound when I do ctr V. After that the copy in memory appears to
be
erased because ctr V on the original sheet does not a thing anymore. I
noticed that after ctr C as soon as I hit enter the copy possibility
is
gone, because I see that the corresponding copy buttons at once are
grayed
out. That happens even right after ctr C when I hit the enter key. The
gray
out occurs also as soon as I hit the tab of another sheet or switch to
another workbook.

Another strange thing is that when after ctr C I click another cell on
the
same sheet and hit enter the same occurs as after ctr V, aaa is
copied!
As I
said, if I hit enter before I take the cursor (mouse pointer) away
from
the
original cell the copying process is aborted.

I tried to overcome this by going back to a system repair point (don't
know
the proper English name) of almost three weeks ago - when the problems
did
not yet occur - but to no avail.

I am in urgent need of help. Your advice will be appreciated.

Jack Sons
The Netherlands





--

Dave Peterson




Dave Peterson

You can keep book.xlt, but remove the code from its project. You may want to
keep book.xlt if you have other settings you want new workbooks to inherit.

I wouldn't call it book.xla. I'd call it something like:
HideZerosAddin.xla

I'd guess it was this line (since it's the only line in the procedure):
ActiveWindow.DisplayZeros = False

When you have lots of lines in the procedure, you can add a few:
Debug.print "1. " & application.cutcopymode

after each line (change the number so you can uniquely identify where it gets
lost).

And then look at the immediate window to see when the status changes.





Jack Sons wrote:

Dave,

Thanks for all your advice. I already removed book.xlt. I will try the addin
way.

Put the code in a nice dedicated workbook in your addin folder.

Do I have to call it book.xla?

First, lots of macros destroy the cutcopymode status.

But what line in the removed code caused it?

Jack.

"Dave Peterson" schreef in bericht
...
First, lots of macros destry the cutcopymode status. It sounds like the
application event that runs each time you activate a different sheet is
doing
it.

So you have a choice to make. Keep the macro and live with the copy|paste
problem or kill the macro and bring back the copy|paste abilility. I
don't
think that there's any other way around it.

And secondly, the macro you pasted shouldn't be in book.xlt. It should be
in
personal.xls.

===

Another option (maybe it'll be sufficient for you).

Move that code out of personal.xls (assuming you've already removed it
from
book.xlt).

Put the code in a nice dedicated workbook in your addin folder.

Then you can install the addin via Tools|Addins.

If you want to turn it off, just uncheck it in tools|addins. (Toggle it
back on
when you absolutely need it.)

===
I still would have had a dedicated macro that would run on demand!

Jack Sons wrote:

David,

I already rebooted a hundred times in the last days.
I checked already (of course) that no sheet or book was protected.
I also was afraid of ongoing searches myself and already tried to see if
a
search was running but could not detect any.
I checked also the the ThisWorkbook module of the only open workbook, it
(of
course) contained no macros, how could it have macros.

Your explicit questions made me think further (thank you for that), at
once
it struck me that hidden files were also open, like personal.xls and my
book.xlt, both in my XLSTART. In book.xlt I put macros (see below the
dotted
line at the end of this email) I recently got from Dave Peterson. The
purpose of these macros was to ensure that every newly opened sheet of an
existing workbook and every sheet of a newly opened wokbook would have
the
option "display zeros" checked out. For some misterious reason I always
have
zeros representated on new sheets and new workbooks, so every time I have
to
go to toolsoptionsa tab in English maybe called view (I use the Dutch
version) and then have to uncheck the option about visible zeros, I mean
the
middle checkbox of the lowest line of checkboxes. It is so annoying that
I
was glad to have these macros.

When I got rid of book.xlt or made the macros inactive by putting '
before
each line my problem was over.

To my regret I can't see why these macros cuased my trouble, it seems
they
contain no search actions or any other code that prevents copying to any
onther sheet. Could you please explain? Also, could you augment these
macros
so that they ensure that the zeros option is checked out but without
causing
other troubles? If that is not possible, is there any problemless method
to
get rid automatically (bij default) of zeros in spreadsheets?

I am looking forward to your explanation and your advice. Up to now it
was
already invaluable to me, I am quite relieved, a thouthand thanks.

Jack.
---------------------------------------------------------------------------------
'Option Explicit
'Public WithEvents xlApp As Application
'Private Sub Workbook_BeforeClose(Cancel As Boolean)
' Set xlApp = Nothing
'End Sub
'Private Sub Workbook_Open()
' Set xlApp = Application
'End Sub
'Private Sub xlApp_SheetActivate(ByVal Sh As Object)
' ActiveWindow.DisplayZeros = False
'End Sub
'Private Sub xlApp_WorkbookActivate(ByVal Wb As Workbook)
' ActiveWindow.DisplayZeros = False
'End Sub

"David McRitchie" schreef in bericht
...
I can't spot the problem but take a look at
Grayed Out Options
http://www.mvps.org/dmcritchie/excel/grayedout.htm

check if the sheet or workbook is protected,
may change copying of formulas to values instead

Make sure you don't have any search going on
file search, text search in files, Outlook Express search
they don't gray out the buttons but you do get invalid results
Sometimes the menus work better for these than the shortcut keys.

Try opening workbook without macros. Check ThisWorkbook for
macros. (right click on Excel logo left of menu bar, view code)

Have you been through a reboot.

I've had strange things happen with a stuck Ctrl key, but I can't
see how any key would cause what you describe.

---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Jack Sons" wrote in message
...
Hi all,

I've got a severe problem. My Excel 2000 (with XP sp2) wil no longer
copy
anything to another sheet of the workbook or another workbook.

I start Excel, open a new workbooks and type in a cel e.g. "aaa"
(without
the ") and enter. All looks normal. If I click on that cell then with
ctr
C
and crt V (or with the copy buttons) I can copy its content to any
other
cell on the same worksheet, but not to another sheet of the same
workbook,
let alone another workbook. In that case I get no error message but
only
a
"plong"sound when I do ctr V. After that the copy in memory appears to
be
erased because ctr V on the original sheet does not a thing anymore. I
noticed that after ctr C as soon as I hit enter the copy possibility
is
gone, because I see that the corresponding copy buttons at once are
grayed
out. That happens even right after ctr C when I hit the enter key. The
gray
out occurs also as soon as I hit the tab of another sheet or switch to
another workbook.

Another strange thing is that when after ctr C I click another cell on
the
same sheet and hit enter the same occurs as after ctr V, aaa is
copied!
As I
said, if I hit enter before I take the cursor (mouse pointer) away
from
the
original cell the copying process is aborted.

I tried to overcome this by going back to a system repair point (don't
know
the proper English name) of almost three weeks ago - when the problems
did
not yet occur - but to no avail.

I am in urgent need of help. Your advice will be appreciated.

Jack Sons
The Netherlands





--

Dave Peterson


--

Dave Peterson

David McRitchie

If you have/keep a book.xlt as your default template for new workbooks
you probably want to also have a sheet.xlt for new worksheets
added to any workbook

---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Dave Peterson" wrote in message ...
You can keep book.xlt, but remove the code from its project. You may want to
keep book.xlt if you have other settings you want new workbooks to inherit.

I wouldn't call it book.xla. I'd call it something like:
HideZerosAddin.xla

I'd guess it was this line (since it's the only line in the procedure):
ActiveWindow.DisplayZeros = False

When you have lots of lines in the procedure, you can add a few:
Debug.print "1. " & application.cutcopymode

after each line (change the number so you can uniquely identify where it gets
lost).

And then look at the immediate window to see when the status changes.





Jack Sons wrote:

Dave,

Thanks for all your advice. I already removed book.xlt. I will try the addin
way.

Put the code in a nice dedicated workbook in your addin folder.

Do I have to call it book.xla?

First, lots of macros destroy the cutcopymode status.

But what line in the removed code caused it?

Jack.

"Dave Peterson" schreef in bericht
...
First, lots of macros destry the cutcopymode status. It sounds like the
application event that runs each time you activate a different sheet is
doing
it.

So you have a choice to make. Keep the macro and live with the copy|paste
problem or kill the macro and bring back the copy|paste abilility. I
don't
think that there's any other way around it.

And secondly, the macro you pasted shouldn't be in book.xlt. It should be
in
personal.xls.

===

Another option (maybe it'll be sufficient for you).

Move that code out of personal.xls (assuming you've already removed it
from
book.xlt).

Put the code in a nice dedicated workbook in your addin folder.

Then you can install the addin via Tools|Addins.

If you want to turn it off, just uncheck it in tools|addins. (Toggle it
back on
when you absolutely need it.)

===
I still would have had a dedicated macro that would run on demand!

Jack Sons wrote:

David,

I already rebooted a hundred times in the last days.
I checked already (of course) that no sheet or book was protected.
I also was afraid of ongoing searches myself and already tried to see if
a
search was running but could not detect any.
I checked also the the ThisWorkbook module of the only open workbook, it
(of
course) contained no macros, how could it have macros.

Your explicit questions made me think further (thank you for that), at
once
it struck me that hidden files were also open, like personal.xls and my
book.xlt, both in my XLSTART. In book.xlt I put macros (see below the
dotted
line at the end of this email) I recently got from Dave Peterson. The
purpose of these macros was to ensure that every newly opened sheet of an
existing workbook and every sheet of a newly opened wokbook would have
the
option "display zeros" checked out. For some misterious reason I always
have
zeros representated on new sheets and new workbooks, so every time I have
to
go to toolsoptionsa tab in English maybe called view (I use the Dutch
version) and then have to uncheck the option about visible zeros, I mean
the
middle checkbox of the lowest line of checkboxes. It is so annoying that
I
was glad to have these macros.

When I got rid of book.xlt or made the macros inactive by putting '
before
each line my problem was over.

To my regret I can't see why these macros cuased my trouble, it seems
they
contain no search actions or any other code that prevents copying to any
onther sheet. Could you please explain? Also, could you augment these
macros
so that they ensure that the zeros option is checked out but without
causing
other troubles? If that is not possible, is there any problemless method
to
get rid automatically (bij default) of zeros in spreadsheets?

I am looking forward to your explanation and your advice. Up to now it
was
already invaluable to me, I am quite relieved, a thouthand thanks.

Jack.
---------------------------------------------------------------------------------
'Option Explicit
'Public WithEvents xlApp As Application
'Private Sub Workbook_BeforeClose(Cancel As Boolean)
' Set xlApp = Nothing
'End Sub
'Private Sub Workbook_Open()
' Set xlApp = Application
'End Sub
'Private Sub xlApp_SheetActivate(ByVal Sh As Object)
' ActiveWindow.DisplayZeros = False
'End Sub
'Private Sub xlApp_WorkbookActivate(ByVal Wb As Workbook)
' ActiveWindow.DisplayZeros = False
'End Sub

"David McRitchie" schreef in bericht
...
I can't spot the problem but take a look at
Grayed Out Options
http://www.mvps.org/dmcritchie/excel/grayedout.htm

check if the sheet or workbook is protected,
may change copying of formulas to values instead

Make sure you don't have any search going on
file search, text search in files, Outlook Express search
they don't gray out the buttons but you do get invalid results
Sometimes the menus work better for these than the shortcut keys.

Try opening workbook without macros. Check ThisWorkbook for
macros. (right click on Excel logo left of menu bar, view code)

Have you been through a reboot.

I've had strange things happen with a stuck Ctrl key, but I can't
see how any key would cause what you describe.

---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Jack Sons" wrote in message
...
Hi all,

I've got a severe problem. My Excel 2000 (with XP sp2) wil no longer
copy
anything to another sheet of the workbook or another workbook.

I start Excel, open a new workbooks and type in a cel e.g. "aaa"
(without
the ") and enter. All looks normal. If I click on that cell then with
ctr
C
and crt V (or with the copy buttons) I can copy its content to any
other
cell on the same worksheet, but not to another sheet of the same
workbook,
let alone another workbook. In that case I get no error message but
only
a
"plong"sound when I do ctr V. After that the copy in memory appears to
be
erased because ctr V on the original sheet does not a thing anymore. I
noticed that after ctr C as soon as I hit enter the copy possibility
is
gone, because I see that the corresponding copy buttons at once are
grayed
out. That happens even right after ctr C when I hit the enter key. The
gray
out occurs also as soon as I hit the tab of another sheet or switch to
another workbook.

Another strange thing is that when after ctr C I click another cell on
the
same sheet and hit enter the same occurs as after ctr V, aaa is
copied!
As I
said, if I hit enter before I take the cursor (mouse pointer) away
from
the
original cell the copying process is aborted.

I tried to overcome this by going back to a system repair point (don't
know
the proper English name) of almost three weeks ago - when the problems
did
not yet occur - but to no avail.

I am in urgent need of help. Your advice will be appreciated.

Jack Sons
The Netherlands





--

Dave Peterson


--

Dave Peterson





All times are GMT +1. The time now is 02:15 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com