Excel question

Professional Engineer & PE Exam Forum

Help Support Professional Engineer & PE Exam Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.

Supe

Well-known member
Joined
Jul 17, 2008
Messages
14,053
Reaction score
3,797
Location
.
Is there a way to increment part of a cell in Excel?

I have a situation where I have a form that shows 6 welds or so on a page, and a few boxes for inspection criteria. For the most part, the number I need to increment shows up about every other cell, but is interrupted by a "comments box" at the end of those 6 welds.

In the weld number box, there is always a line number prefix that stays the same for that form, while the weld number increments. i.e "RW-104-1, RW-104-2, RW-104-3", etc. What I basically need is a way of inputting "if the prefix = "RW-104-", then increment last digit".

Any way of pulling this one off?

 
I pull out the contatenate command: put the prefix in one column, then the number in the next column, then contatenate in the third column. There is probably a better way, but this works for me. Help will show you the proper syntax.

 
Last edited by a moderator:
that's what I do too.

enter "RW-104-" into cell A1 and copy down as many rows as you want.

enter a 1 into cell B1 and in B2 enter =B1+1 (or wahtever your increment is) and copy down as many rows as you need

enter "=A1&B1" into Cell C1 and copy down as many rows as you need.

Column c should now display all the names you need.

Highlight column C and copy, then "paste special-> values into the same range. this gets rid of the formula and make the cell contents fixed with your label.

I do it all the time. hope that helps.

 
Last edited by a moderator:
Thanks, I'll have to give it a shot. The changing cell spacing is the only part that concerns me. Skipping around sure is a PITA, because on this one, I have 1500 of them or so to number.

 
Back
Top