Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
cru cru is offline
external usenet poster
 
Posts: 9
Default Error Message: "Can't Execute Code in Break Mode"

Hi Everyone,

Does anyone know why I would get this error message?

Here's the code:
Sub Comp_Button()

Sheets("Input Form").Unprotect "password"
Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D31 ,D32,G32,A55,A57,A59").Select
Selection.CheckSpelling

Range("Y29:BG29").Select
Selection.Copy
Sheets("REFUND SPREADSHEET").Activate
'Range("A4").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
End Sub
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default Error Message: "Can't Execute Code in Break Mode"

I was thinking the spell check might be the culprit, but I could not get it
to duplicate the error so maybe Don's code will clear it up.

"cru" wrote:

The code is breaking on the

Range("Y29:BG29").Select


thanks for your help!

"galimi" wrote:

What line is this code breaking on?
--
http://HelpExcel.com




"cru" wrote:

Hi Everyone,

Does anyone know why I would get this error message?

Here's the code:
Sub Comp_Button()

Sheets("Input Form").Unprotect "password"
Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D31 ,D32,G32,A55,A57,A59").Select
Selection.CheckSpelling

Range("Y29:BG29").Select
Selection.Copy
Sheets("REFUND SPREADSHEET").Activate
'Range("A4").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
End Sub

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,124
Default Error Message: "Can't Execute Code in Break Mode"


Perhaps you meant to select the Input Form sheet?. However, selections
aren't necessary or desirable

Sub checkspelling()'Notice the DOTS on the indented lines
With Sheets("Input Form")
.Unprotect "password"
.Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D3 1,D32,G32,A55,A57,A59").checkspelling
.Range("Y29:BG29").Copy
Sheets("REFUND SPREADSHEET").Range("A4").PasteSpecial Paste:=xlPasteValues
.protect "password"
End With
End Sub

Sub Comp_Button()

Sheets("Input Form").Unprotect "password"
Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D31 ,D32,G32,A55,A57,A59").Select
Selection.CheckSpelling

Range("Y29:BG29").Select
Selection.Copy
Sheets("REFUND SPREADSHEET").Activate
'Range("A4").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
End Sub


--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"cru" wrote in message
...
Hi Everyone,

Does anyone know why I would get this error message?

Here's the code:
Sub Comp_Button()

Sheets("Input Form").Unprotect "password"
Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D31 ,D32,G32,A55,A57,A59").Select
Selection.CheckSpelling

Range("Y29:BG29").Select
Selection.Copy
Sheets("REFUND SPREADSHEET").Activate
'Range("A4").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
End Sub




  #6   Report Post  
Posted to microsoft.public.excel.programming
cru cru is offline
external usenet poster
 
Posts: 9
Default Error Message: "Can't Execute Code in Break Mode"

Don,

Thank you for information.

Can I just insert the first three lines into the Comp_Button? (I'm sorry
for the stupid question).

I wanted to run the spell checking upon pressing_comp button and then
copy/paste the information on Y29:BG29 into Refund Spreadsheet.

thanks.


"Don Guillett" wrote:


Perhaps you meant to select the Input Form sheet?. However, selections
aren't necessary or desirable

Sub checkspelling()'Notice the DOTS on the indented lines
With Sheets("Input Form")
.Unprotect "password"
.Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D3 1,D32,G32,A55,A57,A59").checkspelling
.Range("Y29:BG29").Copy
Sheets("REFUND SPREADSHEET").Range("A4").PasteSpecial Paste:=xlPasteValues
.protect "password"
End With
End Sub

Sub Comp_Button()

Sheets("Input Form").Unprotect "password"
Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D31 ,D32,G32,A55,A57,A59").Select
Selection.CheckSpelling

Range("Y29:BG29").Select
Selection.Copy
Sheets("REFUND SPREADSHEET").Activate
'Range("A4").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
End Sub


--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"cru" wrote in message
...
Hi Everyone,

Does anyone know why I would get this error message?

Here's the code:
Sub Comp_Button()

Sheets("Input Form").Unprotect "password"
Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D31 ,D32,G32,A55,A57,A59").Select
Selection.CheckSpelling

Range("Y29:BG29").Select
Selection.Copy
Sheets("REFUND SPREADSHEET").Activate
'Range("A4").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
End Sub



  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,124
Default Error Message: "Can't Execute Code in Break Mode"


That's exactly what my macro does, AS WRITTEN. Try it.
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"cru" wrote in message
...
Don,

Thank you for information.

Can I just insert the first three lines into the Comp_Button? (I'm sorry
for the stupid question).

I wanted to run the spell checking upon pressing_comp button and then
copy/paste the information on Y29:BG29 into Refund Spreadsheet.

thanks.


"Don Guillett" wrote:


Perhaps you meant to select the Input Form sheet?. However, selections
aren't necessary or desirable

Sub checkspelling()'Notice the DOTS on the indented lines
With Sheets("Input Form")
.Unprotect "password"

.Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D3 1,D32,G32,A55,A57,A59").checkspelling
.Range("Y29:BG29").Copy
Sheets("REFUND SPREADSHEET").Range("A4").PasteSpecial
Paste:=xlPasteValues
.protect "password"
End With
End Sub

Sub Comp_Button()

Sheets("Input Form").Unprotect "password"
Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D31 ,D32,G32,A55,A57,A59").Select
Selection.CheckSpelling

Range("Y29:BG29").Select
Selection.Copy
Sheets("REFUND SPREADSHEET").Activate
'Range("A4").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
End Sub


--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"cru" wrote in message
...
Hi Everyone,

Does anyone know why I would get this error message?

Here's the code:
Sub Comp_Button()

Sheets("Input Form").Unprotect "password"
Range("D12,D13,D14,D15,D17,D22,D24,D26,D29,D30,D31 ,D32,G32,A55,A57,A59").Select
Selection.CheckSpelling

Range("Y29:BG29").Select
Selection.Copy
Sheets("REFUND SPREADSHEET").Activate
'Range("A4").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
End Sub




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
Any ideas "can't enter break mode at this time" error gone amok ArielMalek Excel Programming 1 July 12th 08 08:15 AM
"can't enter break mode at this time" message when adding a projectreference dbKemp Excel Programming 0 January 30th 08 03:12 PM
What does this mean? "Can't execute code in design mode" Danni2004 Excel Discussion (Misc queries) 4 September 27th 07 11:22 PM
OnTime code error "can't execute code in break mode" tskogstrom Excel Programming 1 September 8th 06 10:29 AM
"CAN'T EXECUTE CODE IN BREAK MODE" Chuckles123[_72_] Excel Programming 2 November 22nd 04 05:06 AM


All times are GMT +1. The time now is 09:03 PM.

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

About Us

"It's about Microsoft Excel"