Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 54
Default Error message

Hi,

I have encountered a problem with the following code and am receiving this
message - object variable or with block variable not set. Can someone
advise??

Private Sub CommandButton1_Click()

Sheets("quote2").Range("appendix").Copy

Sheets("contract").Select
Cells.FindNext(After:=ActiveCell).Activate

Cells.Find(What:="appendix", _
After:=ActiveCell, LookIn:=xlFormulas, _
LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, _
MatchCase:=False).Activate

ActiveCell.Offset(1, 0).Select
ActiveSheet.Paste
End Sub


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 54
Default Error message

please ignore this post, the problem has been rectified!!

Cheers!!!!


"gav meredith" wrote in message
...
Hi,

I have encountered a problem with the following code and am receiving this
message - object variable or with block variable not set. Can someone
advise??

Private Sub CommandButton1_Click()

Sheets("quote2").Range("appendix").Copy

Sheets("contract").Select
Cells.FindNext(After:=ActiveCell).Activate

Cells.Find(What:="appendix", _
After:=ActiveCell, LookIn:=xlFormulas, _
LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, _
MatchCase:=False).Activate

ActiveCell.Offset(1, 0).Select
ActiveSheet.Paste
End Sub




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 54
Default Error message

.....and once again the problem presents itself. I apologise for the
confusion. It appears when there is a large qty of data to copy, the error
occurs.

Any ideas???

Thanks all!!!!

"gav meredith" wrote in message
...
please ignore this post, the problem has been rectified!!

Cheers!!!!


"gav meredith" wrote in message
...
Hi,

I have encountered a problem with the following code and am receiving

this
message - object variable or with block variable not set. Can someone
advise??

Private Sub CommandButton1_Click()

Sheets("quote2").Range("appendix").Copy

Sheets("contract").Select
Cells.FindNext(After:=ActiveCell).Activate

Cells.Find(What:="appendix", _
After:=ActiveCell, LookIn:=xlFormulas, _
LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, _
MatchCase:=False).Activate

ActiveCell.Offset(1, 0).Select
ActiveSheet.Paste
End Sub






  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 54
Default Error message

this is the line of code it refers to...

Cells.FindNext(After:=ActiveCell).Activate

thank you

"gav meredith" wrote in message
...
....and once again the problem presents itself. I apologise for the
confusion. It appears when there is a large qty of data to copy, the error
occurs.

Any ideas???

Thanks all!!!!

"gav meredith" wrote in message
...
please ignore this post, the problem has been rectified!!

Cheers!!!!


"gav meredith" wrote in message
...
Hi,

I have encountered a problem with the following code and am receiving

this
message - object variable or with block variable not set. Can someone
advise??

Private Sub CommandButton1_Click()

Sheets("quote2").Range("appendix").Copy

Sheets("contract").Select
Cells.FindNext(After:=ActiveCell).Activate

Cells.Find(What:="appendix", _
After:=ActiveCell, LookIn:=xlFormulas, _
LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, _
MatchCase:=False).Activate

ActiveCell.Offset(1, 0).Select
ActiveSheet.Paste
End Sub








  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default Find generates error message

hi seamus

i am still having troubles unfortunately. Would it be possible for me to send you my workbook for you, or anyone willing, to look at??

Thanks!

----- SOS wrote: ----

Hi gav

On trying to emulate your problem I could only do so if the tex
"appendix" was not in sheet ("contract")

After adding "appendix" to a cell in sheet ("contract") the code ra
fine no matter the size of the range "appendix"

Regard

Seamu


--
Message posted from http://www.ExcelForum.com


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
Error message #N/A ISAF Media Analysis[_2_] Excel Discussion (Misc queries) 5 February 16th 09 12:34 PM
VBA Error Message "Compile Error...." Steve Excel Discussion (Misc queries) 3 July 15th 05 09:20 AM
changing the message in an error message The Villages DA Excel Worksheet Functions 2 February 18th 05 05:30 PM
Help with error message - please! Pat Excel Worksheet Functions 4 January 29th 05 10:16 AM
How do I get rid of "Compile error in hidden module" error message David Excel Discussion (Misc queries) 4 January 21st 05 11:39 PM


All times are GMT +1. The time now is 09:40 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"