Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Copy and Paste
 
Posts: n/a
Default how can I paste 10 cells but inverting the position of the cells

I'd like to copy 10 cells and paste them inverted, last cell first and first
cell last, not transpose, but vertically. Like fliping the 10 cells.
  #2   Report Post  
Posted to microsoft.public.excel.misc
mattgoof2005
 
Posts: n/a
Default how can I paste 10 cells but inverting the position of the cells

If you're planning to do this multiple times and it will always be 10 cells,
you could record a macro for it.

"Copy and Paste" wrote:

I'd like to copy 10 cells and paste them inverted, last cell first and first
cell last, not transpose, but vertically. Like fliping the 10 cells.

  #3   Report Post  
Posted to microsoft.public.excel.misc
Copy and Paste
 
Posts: n/a
Default how can I paste 10 cells but inverting the position of the cel

Sometimes it will be more than ten. Is there a way to do this without using
macros?

"mattgoof2005" wrote:

If you're planning to do this multiple times and it will always be 10 cells,
you could record a macro for it.

"Copy and Paste" wrote:

I'd like to copy 10 cells and paste them inverted, last cell first and first
cell last, not transpose, but vertically. Like fliping the 10 cells.

  #4   Report Post  
Posted to microsoft.public.excel.misc
Ken Johnson
 
Posts: n/a
Default how can I paste 10 cells but inverting the position of the cells


Copy and Paste wrote:
I'd like to copy 10 cells and paste them inverted, last cell first and first
cell last, not transpose, but vertically. Like fliping the 10 cells.

If you have a nearby spare column with numbers 1 to 10 (or any other
sequence of increasing numbers) down that column in the same rows as
your 10 cells you are wanting to copy then invert, you could invert
them before copying, then paste the inverted copy. To invert before
copy just select a range of cells includes your 10 cells for inversion
and the cells with increasing numbers, then sort by the increasing
numbers column in decreasing order. Then do the copy/paste, then resort
ascending order to restore the original data's order.

Ken Johnson

  #5   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson
 
Posts: n/a
Default how can I paste 10 cells but inverting the position of the cel

A macro might be the simplest way.

If you want to try:

Option Explicit
Sub testme03()
Dim FromRng As Range
Dim DestCell As Range
Dim iRow As Long
Dim TotalCells As Long

Set FromRng = Nothing
On Error Resume Next
Set FromRng = Application.InputBox _
(Prompt:="Select a single column range", Type:=8) _
.Areas(1).Columns(1)
On Error GoTo 0

If FromRng Is Nothing Then
Exit Sub
End If

Set DestCell = Nothing
On Error Resume Next
Set DestCell = Application.InputBox _
(Prompt:="Select a single cell", Type:=8).Cells(1)
On Error GoTo 0

TotalCells = FromRng.Cells.Count
For iRow = 1 To TotalCells
DestCell.Offset(iRow - 1, 0).Value _
= FromRng.Cells(TotalCells + 1 - iRow).Value
Next iRow

End Sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm



Copy and Paste wrote:

Sometimes it will be more than ten. Is there a way to do this without using
macros?

"mattgoof2005" wrote:

If you're planning to do this multiple times and it will always be 10 cells,
you could record a macro for it.

"Copy and Paste" wrote:

I'd like to copy 10 cells and paste them inverted, last cell first and first
cell last, not transpose, but vertically. Like fliping the 10 cells.


--

Dave Peterson


  #6   Report Post  
Posted to microsoft.public.excel.misc
Copy and Paste
 
Posts: n/a
Default how can I paste 10 cells but inverting the position of the cel

Hi Dave,

Thank you very much for your answer and for all your help!

"Dave Peterson" wrote:

A macro might be the simplest way.

If you want to try:

Option Explicit
Sub testme03()
Dim FromRng As Range
Dim DestCell As Range
Dim iRow As Long
Dim TotalCells As Long

Set FromRng = Nothing
On Error Resume Next
Set FromRng = Application.InputBox _
(Prompt:="Select a single column range", Type:=8) _
.Areas(1).Columns(1)
On Error GoTo 0

If FromRng Is Nothing Then
Exit Sub
End If

Set DestCell = Nothing
On Error Resume Next
Set DestCell = Application.InputBox _
(Prompt:="Select a single cell", Type:=8).Cells(1)
On Error GoTo 0

TotalCells = FromRng.Cells.Count
For iRow = 1 To TotalCells
DestCell.Offset(iRow - 1, 0).Value _
= FromRng.Cells(TotalCells + 1 - iRow).Value
Next iRow

End Sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm



Copy and Paste wrote:

Sometimes it will be more than ten. Is there a way to do this without using
macros?

"mattgoof2005" wrote:

If you're planning to do this multiple times and it will always be 10 cells,
you could record a macro for it.

"Copy and Paste" wrote:

I'd like to copy 10 cells and paste them inverted, last cell first and first
cell last, not transpose, but vertically. Like fliping the 10 cells.


--

Dave Peterson

  #7   Report Post  
Posted to microsoft.public.excel.misc
Copy and Paste
 
Posts: n/a
Default how can I paste 10 cells but inverting the position of the cel

Hi Ken,

That is a very simple and brilliant idea. I can't believe I didn't think of
it before.
Thank you very much!

"Ken Johnson" wrote:


Copy and Paste wrote:
I'd like to copy 10 cells and paste them inverted, last cell first and first
cell last, not transpose, but vertically. Like fliping the 10 cells.

If you have a nearby spare column with numbers 1 to 10 (or any other
sequence of increasing numbers) down that column in the same rows as
your 10 cells you are wanting to copy then invert, you could invert
them before copying, then paste the inverted copy. To invert before
copy just select a range of cells includes your 10 cells for inversion
and the cells with increasing numbers, then sort by the increasing
numbers column in decreasing order. Then do the copy/paste, then resort
ascending order to restore the original data's order.

Ken Johnson


  #8   Report Post  
Posted to microsoft.public.excel.misc
Ken Johnson
 
Posts: n/a
Default how can I paste 10 cells but inverting the position of the cel

Hi Copy and Paste,

Thanks for those kind words.
I'll pass them on to my superiors:-)

Ken Johnson

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
how to repeat a paste of cells without copying again bobaloo Excel Discussion (Misc queries) 2 April 22nd 06 01:25 PM
How to paste data into multiple cells in Excel wrdennig New Users to Excel 4 April 20th 06 06:43 PM
copy and paste between cells that have data mstack Excel Worksheet Functions 1 November 16th 05 09:16 PM
copy & paste spreadsheet cells from excel to outlook to excel mismarple Excel Discussion (Misc queries) 1 September 20th 05 11:16 PM
Border thickness varies when I paste Excel cells into Word. Sam Excel Discussion (Misc queries) 0 August 31st 05 05:03 PM


All times are GMT +1. The time now is 02:25 AM.

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"