Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ayo Ayo is offline
external usenet poster
 
Posts: 489
Default Help with this code please !!!!!!!

I have use the code set below in other files but in this new file I am
getting an error on "Cells.Select". "Select method of Range class failed"
Any idea whats going on?

Sheets("Completions Summary").Select
Cells.Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues
Application.CutCopyMode = False
Range("A4").Select
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 226
Default Help with this code please !!!!!!!

are you sure you have the sheet name correct?

no need to select, i'd use something like this:

With Worksheets("Completions Summary").Cells
.Copy
.PasteSpecial Paste:=xlPasteValues
Application.CutCopyMode = False
.Range("A4").Select
End With

--


Gary Keramidas
Excel 2003


"Ayo" wrote in message
...
I have use the code set below in other files but in this new file I am
getting an error on "Cells.Select". "Select method of Range class failed"
Any idea whats going on?

Sheets("Completions Summary").Select
Cells.Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues
Application.CutCopyMode = False
Range("A4").Select


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 464
Default Help with this code please !!!!!!!

With Sheets("Completions Summary").UsedRange
.Value = .Value
End With


--
Regards
Dave Hawley
www.ozgrid.com
"Ayo" wrote in message
...
I have use the code set below in other files but in this new file I am
getting an error on "Cells.Select". "Select method of Range class failed"
Any idea whats going on?

Sheets("Completions Summary").Select
Cells.Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues
Application.CutCopyMode = False
Range("A4").Select


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 226
Default Help with this code please !!!!!!!


i personally stay away from using used range. i'd rather find it through
code. the one time it screws up could be costly. you may have other views,
this is just mine.

http://www.contextures.on.ca/xlfaqApp.html#Unused
--


Gary Keramidas
Excel 2003


"ozgrid.com" wrote in message
...
With Sheets("Completions Summary").UsedRange
.Value = .Value
End With


--
Regards
Dave Hawley
www.ozgrid.com
"Ayo" wrote in message
...
I have use the code set below in other files but in this new file I am
getting an error on "Cells.Select". "Select method of Range class
failed"
Any idea whats going on?

Sheets("Completions Summary").Select
Cells.Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues
Application.CutCopyMode = False
Range("A4").Select



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 464
Default Help with this code please !!!!!!!

So do I, but in the case of converting a Worksheet to values, it well
suited.



--
Regards
Dave Hawley
www.ozgrid.com
"Gary Keramidas" wrote in message
...

i personally stay away from using used range. i'd rather find it through
code. the one time it screws up could be costly. you may have other views,
this is just mine.

http://www.contextures.on.ca/xlfaqApp.html#Unused
--


Gary Keramidas
Excel 2003


"ozgrid.com" wrote in message
...
With Sheets("Completions Summary").UsedRange
.Value = .Value
End With


--
Regards
Dave Hawley
www.ozgrid.com
"Ayo" wrote in message
...
I have use the code set below in other files but in this new file I am
getting an error on "Cells.Select". "Select method of Range class
failed"
Any idea whats going on?

Sheets("Completions Summary").Select
Cells.Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues
Application.CutCopyMode = False
Range("A4").Select




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
Creating excel file, adding code to it from code, VBE window stays BlueWolverine Excel Programming 0 November 5th 09 07:55 PM
How can I modify my code to offset the defined range and repeat theprocedure instead of duplicating my code? [email protected] Excel Programming 4 May 29th 09 10:13 PM
Run VBA code only worksheet change, but don't trigger worksheet_change event based on what the code does ker_01 Excel Programming 6 October 3rd 08 09:45 PM
Shorten code to apply to all sheets except a few, instead of individually naming them, and later adding to code. Corey Excel Programming 3 December 11th 06 05:14 AM
Excel code convert to Access code - Concat & eliminate duplicates italia Excel Programming 1 September 12th 06 12:14 AM


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