#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 148
Default On exit?

I was wondering if someone might know how to fix this problem

I run a bunch of code and a table is copied into a summary tab. When this
is first opened and run it gets hung up on a section that reads
Worksheets(CStr(Trim(wsSource.Range("A12")) & "
Platform")).Range("I7:N19").Copy
With target.Offset(3, 0)
.PasteSpecial xlPasteValues
..PasteSpecial xlPasteFormats
End With
Application.CutCopyMode = False

I am guessing that maybe I need to clear the page on return to another tab
or on exit? Does anyone have any ideas? Thanks in advance!!!!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default On exit?

What is the error??? I am guessing subscript out of range??? As a guess you
do not have a sheet

wsSource.Range("A12")) & " Platform"

Purely a guess however...
--
HTH...

Jim Thomlinson


"Heather" wrote:

I was wondering if someone might know how to fix this problem

I run a bunch of code and a table is copied into a summary tab. When this
is first opened and run it gets hung up on a section that reads
Worksheets(CStr(Trim(wsSource.Range("A12")) & "
Platform")).Range("I7:N19").Copy
With target.Offset(3, 0)
.PasteSpecial xlPasteValues
.PasteSpecial xlPasteFormats
End With
Application.CutCopyMode = False

I am guessing that maybe I need to clear the page on return to another tab
or on exit? Does anyone have any ideas? Thanks in advance!!!!

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 148
Default On exit?

It goes to this when it errors? but works the 2nd time around
.PasteSpecial xlPasteValues


Does it need cleared out like maybe when they first hit the macro it clears
and then creates or something

"Jim Thomlinson" wrote:

What is the error??? I am guessing subscript out of range??? As a guess you
do not have a sheet

wsSource.Range("A12")) & " Platform"

Purely a guess however...
--
HTH...

Jim Thomlinson


"Heather" wrote:

I was wondering if someone might know how to fix this problem

I run a bunch of code and a table is copied into a summary tab. When this
is first opened and run it gets hung up on a section that reads
Worksheets(CStr(Trim(wsSource.Range("A12")) & "
Platform")).Range("I7:N19").Copy
With target.Offset(3, 0)
.PasteSpecial xlPasteValues
.PasteSpecial xlPasteFormats
End With
Application.CutCopyMode = False

I am guessing that maybe I need to clear the page on return to another tab
or on exit? Does anyone have any ideas? Thanks in advance!!!!

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default On exit?

What is the Error??? Post the rest of your code
--
HTH...

Jim Thomlinson


"Heather" wrote:

It goes to this when it errors? but works the 2nd time around
.PasteSpecial xlPasteValues


Does it need cleared out like maybe when they first hit the macro it clears
and then creates or something

"Jim Thomlinson" wrote:

What is the error??? I am guessing subscript out of range??? As a guess you
do not have a sheet

wsSource.Range("A12")) & " Platform"

Purely a guess however...
--
HTH...

Jim Thomlinson


"Heather" wrote:

I was wondering if someone might know how to fix this problem

I run a bunch of code and a table is copied into a summary tab. When this
is first opened and run it gets hung up on a section that reads
Worksheets(CStr(Trim(wsSource.Range("A12")) & "
Platform")).Range("I7:N19").Copy
With target.Offset(3, 0)
.PasteSpecial xlPasteValues
.PasteSpecial xlPasteFormats
End With
Application.CutCopyMode = False

I am guessing that maybe I need to clear the page on return to another tab
or on exit? Does anyone have any ideas? Thanks in advance!!!!

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
Exit Field vs Exit Button...... roy_ware Excel Programming 2 October 10th 07 04:05 PM
exit sub RobcPettit[_2_] Excel Programming 3 October 23rd 06 06:03 PM
Exit Sub Raman325[_38_] Excel Programming 4 May 25th 06 08:13 PM
exit while? Steven Deng Excel Programming 1 November 6th 04 12:14 AM
If a called sub exit, how to the caller exit right away? luvgreen[_4_] Excel Programming 4 February 24th 04 05:06 PM


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