View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Don Guillett[_4_] Don Guillett[_4_] is offline
external usenet poster
 
Posts: 2,337
Default Cells.Select

This will copy all used cells in sheet3 from anywhere(NO selections) to the
activesheet!a1
Sub copyworksheetcells()
Sheets("sheet3").UsedRange.Copy Range("a1")'one line
End Sub

Sub copyworksheetcellsvalues()
Sheets("sheet3").UsedRange.Copy 'two lines
Sheets("sheet12").Range("a1").PasteSpecial Paste:=xlPasteValues
End Sub

--
Don Guillett
SalesAid Software

"Rich F" wrote in message
...

HI,

Why won't this run? - It stops at Cells.Select

Sheets("Quote").Select
Cells.Select
Range("A21").Activate
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
ActiveWindow.ScrollRow = 1
Range("I2:R2").Select
ActiveWindow.ScrollWorkbookTabs Sheets:=1
Sheets("EMA Savings Calculator").Select
Cells.Select
Range("A14").Activate
Application.CutCopyMode = False
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
ActiveWindow.ScrollRow = 1
Range("D2:F3").Select
ActiveWindow.ScrollWorkbookTabs Position:=xlFirst
Sheets(Array("Customer - Rep Info", "Machine Selection")).Select
Sheets("Machine Selection").Activate
ActiveWindow.SelectedSheets.Visible = False

Thanks -


--
Rich F
------------------------------------------------------------------------
Rich F's Profile:

http://www.excelforum.com/member.php...fo&userid=9666
View this thread: http://www.excelforum.com/showthread...hreadid=278363