+ Reply to Thread
Results 1 to 2 of 2

Row Numbering (First four of same number assigned 1, remaining of number assigned 10000)

Hybrid View

  1. #1
    Registered User
    Join Date
    08-11-2015
    Location
    Canada
    MS-Off Ver
    2010 pc
    Posts
    3

    Row Numbering (First four of same number assigned 1, remaining of number assigned 10000)

    Hi Guys,

    Bit of a weird scenario here that I haven't run into before. Basically I have a sorted item number in column A and need to assign a family number in column B. The first four rows of a given item number get the family numbers starting from 1, with the remaining rows of that number assigned a family number starting at 10000. The number of rows each item number appears varies but basically i need to come up with a formula or macro to number the first for "1" and the reaming "10,000" increasing by 1 for each new item number.

    Item Number Family Number
    6033383 1
    6033383 1
    6033383 1
    6033383 1
    6033383 10001
    6033383 10001
    6033383 10001
    7384938 2
    7384938 2
    7384938 2
    7384938 2
    7384938 10002
    2893726 3
    2893726 3
    2893726 3
    2893726 3
    2893726 10003
    2893726 10003
    1328938 =??????????
    1328938 =??????????
    Attached Images Attached Images

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Row Numbering (First four of same number assigned 1, remaining of number assigned 1000

    See if this is what you want...
    =IF(A2=A1,IF(COUNTIF($A$2:A2,A2)=5,10000+C1,C1),IF(ISNUMBER(C1),--RIGHT(C1,3)+1,1))
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. if then macro to find word and update another cell in row with an assigned number
    By carolinapos in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-19-2014, 07:12 PM
  2. Add cells with letter values assigned a number
    By muels7 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-15-2014, 11:27 AM
  3. [SOLVED] Change letters,characters and moves to an assigned number
    By sherryp5165 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-04-2013, 04:59 PM
  4. [SOLVED] Pairing up names based on their assigned number
    By hexr in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 02-06-2013, 07:33 PM
  5. Show duplicate assigned number in a list
    By klturi421 in forum Excel General
    Replies: 3
    Last Post: 01-19-2012, 01:12 PM
  6. run different code upon the number assigned in textbox
    By copythat in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 11-28-2011, 06:23 PM
  7. Random numbers plus assigned number
    By mutchdea in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-28-2009, 09:57 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1