LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default AutoFill without sequential order

Hello,
I'd like to copy B1:B3 then autofill it till the last row of column A without
the number sequence. Here's my code, I don't know what variables to change or
add. Still new at this.


Sub Step2Add_New_Column()
'
' Step2Add_New_Column Macro
'

'

Dim LR As Integer

Columns("B:B").Select
Selection.Insert Shift:=xlToRight
Range("B1").Select
ActiveCell.FormulaR1C1 = "direct"
Range("B2").Select
ActiveCell.FormulaR1C1 = "indirect1"
Range("B3").Select
ActiveCell.FormulaR1C1 = "indirect2"
LR = Range("A" & Rows.Count).End(xlUp).Row
Range("B1:B3").Select
Selection.AutoFill Destination:=Range("B1:B" & LR)
Range("B1:B" & LR).Select
Selection.Copy
Application.CutCopyMode = False

With Selection
.HorizontalAlignment = xlRight
.VerticalAlignment = xlBottom
.WrapText = False
.Orientation = 0
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = False
End With

End Sub

Thanks for your time in advance!
 
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
autofill variable lenght column w/ sequential numbers using VBA Billyruben Excel Discussion (Misc queries) 2 November 28th 08 01:29 AM
LOOPING BUT THE MARKS ARE NOT IN SEQUENTIAL ORDER [email protected] Excel Programming 4 April 29th 06 02:55 AM
LOOPING BUT THE MARKS ARE NOT IN SEQUENTIAL ORDER #3 [email protected] Excel Programming 1 April 29th 06 02:55 AM
Creating a list in sequential order Mark Jackson Excel Worksheet Functions 6 November 7th 05 11:08 PM
AutoFill with Non-sequential Cell References ? [email protected] Excel Worksheet Functions 3 June 20th 05 03:39 AM


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