LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 13
Default autofill variable lenght column w/ sequential numbers using VBA

Problem: Sort data contained in an area defined by X number of columns and Y
number of rows, then sort the data back to its orginal row order.

Normally: Before the initial sort, add an extra column and assign a unique
number to each row. Sort using this extra column will restore the original
row order.

I can record a macro and display the VBA code without a problem.

Question: Write the code identifying the last sort row when # of rows not
constant. eg: Selection.AutoFill Destination:=Range("F5:F??"),
Type:=xlFillDefault. I can count the # of rows, but how do I store that
number, then pass it to the Range requirements?
 
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
Fill a column with sequential numbers GISDude Excel Discussion (Misc queries) 4 May 1st 06 02:41 PM
Fill a column with sequential numbers GISDude Excel Discussion (Misc queries) 3 May 1st 06 02:01 AM
String parsing with variable lenght strings frosterrj Excel Worksheet Functions 10 March 31st 06 11:46 PM
how do I autofil a column with sequential numbers? Yesrek Excel Discussion (Misc queries) 1 November 20th 05 12:14 AM
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 07:58 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"