Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default insert cells in alternating rows?

I wish to add cells to alternating rows to move the info over to the next
column.
Is it possible to do that without highlighting each row?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 123
Default insert cells in alternating rows?

You would need a macro like the following:

Sub MoveAlternating()
'starting in a selected cell this macro checks for content and then
'moves data in a cell one column to the right in alternating rows
'skip first row of data
ActiveCell.Offset(1, 0).Range("A1").Select
While ActiveCell < ""
Selection.Insert Shift:=xlToRight
ActiveCell.Offset(2, 0).Range("A1").Select
Wend
End Sub

It skips the first row and then moves every other row's data over one
column to the right. It will stop when it encounters the first blank
cell.

Let me know if that's not what you were looking for.

On May 30, 4:02 pm, happygal
wrote:
I wish to add cells to alternating rows to move the info over to the next
column.
Is it possible to do that without highlighting each row?


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
Problem with alternating table rows Linda Excel Discussion (Misc queries) 2 June 18th 07 01:30 PM
Alternating BG colors between groups of rows WhiteFantom Excel Discussion (Misc queries) 2 December 16th 06 06:05 PM
How do I insert alternating blank rows in a list of data? curiouscat Excel Worksheet Functions 5 September 18th 06 11:09 PM
shade alternating rows in excel Matt8301 Excel Discussion (Misc queries) 2 July 28th 05 08:54 PM
Alternating colors for rows jp Excel Discussion (Misc queries) 1 December 28th 04 09:00 PM


All times are GMT +1. The time now is 05:20 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"