+ Reply to Thread
Results 1 to 6 of 6

Incrementing number based number range

  1. #1
    Registered User
    Join Date
    03-21-2009
    Location
    Bangalore
    MS-Off Ver
    Excel 2003
    Posts
    60

    Incrementing number based number range

    Hi Dear forum members,

    I have data like Table A and want to split data as mentioned in Table B. The numbers between the range should increment and copy to next row along with County, Price.

    I have huge data like this . I am able to split data by semicolon but unable to increment numbers.

    Kindly provide macro for this scenario. Thanks in Advance

    Table A
    County Range Number Price

    USA 632295-632298; 632340-632348; 632395-632399 2.5
    India 6346580-6346585; 6346590-6346598;6346599-6346620 3.5
    Sweden 6346621-6346630; 6346633-6346639; 6346641-6346649 2.8


    Table B

    County Range Number Price

    USA 632295 205
    USA 632296 205
    USA 632297 205
    USA 632298 205
    USA 632340 205
    USA 632341 205
    USA 632342 205
    USA 632343 205
    USA 632344 205
    USA 632345 205
    USA 632346 205
    USA 632347 205
    USA 632348 205
    USA 632395 205
    USA 632396 205
    USA 632397 205
    USA 632398 205
    USA 632399 205
    India 6346580 3.5
    India 6346581 3.5
    India 6346582 3.5
    India 6346583 3.5
    India 6346584 3.5
    India 6346585 3.5

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,139

    Re: Incrementing number based number range

    Point 1. I cannot see what is in which cell. Will you please attach a SMALL sample Excel workbook (10-20 rows of data is usually enough)? Please don't attach a picture of one (no-one will want to re-type all your stuff before starting).

    1. Make sure that your sample data are truly REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    2. Make sure that your desired solution is also shown (mock up the results manually).

    3. Make sure that all confidential information is removed first!!

    4. Try to avoid using merged cells. They cause lots of problems!

    Unfortunately the attachment icon doesn't work at the moment. So, to attach an Excel file you have to do the following: Just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.

    Point 2. Is a formula acceptable?
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  3. #3
    Registered User
    Join Date
    03-21-2009
    Location
    Bangalore
    MS-Off Ver
    Excel 2003
    Posts
    60

    Re: Incrementing number based number range

    Thanks Glenn,

    I have attached sample data sheet to this thread. I have huge data like "632295-632298" this number range. The range should increment by one and should add in next cell.

    Please see the sample test data that is attached. The data in Table A should display as Table B in test data sheet.


    Thanks
    Rams
    Attached Files Attached Files

  4. #4
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,584

    Re: Incrementing number based number range

    Try
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    03-21-2009
    Location
    Bangalore
    MS-Off Ver
    Excel 2003
    Posts
    60

    Re: Incrementing number based number range

    Thank you Jindon,

    I tried your code and it's working as I expected.

    Thanks a lot.

    Rams

  6. #6
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,584

    Re: Incrementing number based number range

    You are welcome.
    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

+ 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. Worksheet number not incrementing
    By DaniSlocombe in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 10-20-2017, 12:00 AM
  2. Incrementing Until a Number is Reached
    By skillsguy in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-27-2015, 10:15 PM
  3. Replies: 1
    Last Post: 07-18-2013, 10:11 AM
  4. Auto incrementing PO number
    By rackham in forum Excel Programming / VBA / Macros
    Replies: 23
    Last Post: 10-27-2011, 01:35 PM
  5. Incrementing invoice number
    By txturbo in forum Excel General
    Replies: 2
    Last Post: 04-22-2007, 10:30 PM
  6. [SOLVED] Incrementing row number
    By den1s in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-09-2006, 11:10 AM
  7. Incrementing a formula by X number
    By Bowbender in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-21-2005, 11:14 AM

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