Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 923
Default Help with Numbering Macro

This simple piece of code will increment the first letter by 1 (AB etc),
for the selected range of cells. So after your insert, select all cells (in
column A) after the inserted rows and run this code.

Sub Recode()
Dim c As Range
For Each c In Selection
If Len(Trim(c)) 0 Then c = Chr(Asc(Left(c, 1)) + 1) & Mid(c, 2, Len(c) -
1)
Next
End Sub

--
Cheers
Nigel



"Sprinks" wrote in message
...
We do conceptual cost estimating for architects at early stages of design
in
Excel. We use a standard of 60 lines per page with the following section
conventions. Categories shown are just examples and vary, the # of lines
vary
since 2 or more categories may fit on a single page. What stays
consistent
is that after the last line of a category, there is a blank line followed
by
"Subtotal" in column B.

...header....

A Demolition

A1 Stairs-on-grade 1 LS $1,500.00 1,500
A2 ... other line items
A3 ....
...
An

Subtotal
20,000

-------------------------------------------------------------------------

B Foundations

B1
...
Bn

Subtotal

Frequently, due to space limitations, we find it necessary to insert a new
category, requiring that all subsequent categories need to be re-lettered,
e.g., from B, B1-Bn to C, C1-Cn, n being the last line of the category.
This
is a tedious process that I'd like to automate. I can handle the
inserting a
new page but would like help with the relettering/renumbering.

Can anyone point me in the right direction?

Thank you.
Sprinks



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
Macro for sequential numbering. Jeff W Excel Discussion (Misc queries) 4 July 12th 08 04:18 PM
auto numbering macro JonM4 Excel Programming 1 April 26th 06 01:36 AM
auto numbering macro JonM4 Excel Discussion (Misc queries) 0 April 25th 06 03:20 PM
auto numbering macro JonM4 Excel Worksheet Functions 0 April 25th 06 03:19 PM
numbering macro Maasha New Users to Excel 3 November 22nd 05 07:22 AM


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