+ Reply to Thread
Results 1 to 9 of 9

Problem with Excel pattern equation

  1. #1
    Registered User
    Join Date
    01-20-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    6

    Problem with Excel pattern equation

    Hi guys I'm trying to return the value for a cell using an equation.
    Basically I want it to be like
    B5975
    B5981
    B5987
    and so on (a 6 digit increment)

    I am using this equation: =INDEX(B:B,(ROWS(1:$5975)-1)*6+1)
    But it returns a value of zero, any ideas why??

    Thanks!

  2. #2
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Problem with Excel pattern equation

    Have the cells in columnB got data in them?
    If the cells that the Index formulais pointing to are empty, or if the formula they contain result in a "" or 0, it will return a 0

    Hope this helps
    A picture may be worth a thousand words, BUT, a sample Workbook is worth a thousand screenshots!
    -Add a File - click advanced (next to quick post), scroll to manage attachments, click, select add files, click select files, select file, click upload, when file shows up at bottom left, click done (bottom right), click submit
    -To mark thread Solved- go top of thread,click Thread Tools,click Mark as Solved
    If you received helpful response, please remember to hit the * of that post

  3. #3
    Registered User
    Join Date
    01-20-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    6

    Re: Problem with Excel pattern equation

    Thanks for your response!
    No they are just cells with values in them, I can attach the spreadsheet if that helps?

  4. #4
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Problem with Excel pattern equation

    Reread, to get the result of "B1" instead of the contents of Cell B1:
    start in first row of any column,then
    ="B"&(ROWS($1:1)-1)*6+1
    drag down

    for the contents of B1,B7,B13...
    In say C1:
    =INDEX(B:B,(ROWS($1:1)-1)*6+1)
    Drag down

    Hope this helps

  5. #5
    Registered User
    Join Date
    01-20-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    6

    Re: Problem with Excel pattern equation

    Sorry yes I need the contents, my bad.
    But that equation isn't working because I have to start from cell B5975
    I use this equation =INDEX(B:B,(ROWS(1:$5975)-1)*6+1)
    and it returns the cell contents as 0. Have I done the equation wrong?

    Thanks

  6. #6
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Problem with Excel pattern equation

    Also, if you want to start the offset calculation at a specific point say 5975 and carry on:

    IX (for example) C1:
    ="B"&(ROWS($1:1)-1)*6+5975
    OR
    =INDEX(B:B,(ROWS($1:1)-1)*6+5975)

    Edit-

    Check where the Dollar Sign ($) is placed

  7. #7
    Registered User
    Join Date
    01-20-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    6

    Re: Problem with Excel pattern equation

    Yes! Brilliant, thanks so much dredwolf!!

  8. #8
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Problem with Excel pattern equation

    What row are you starting in?

  9. #9
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Problem with Excel pattern equation

    You are welcome

    Please remember to mark the thread as solved if you are satisfied with your solution :
    To mark thread "Solved", go to the top of the thread,click "Thread Tools",click "Mark as Solved"

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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