+ Reply to Thread
Results 1 to 7 of 7

retrieving values which are not 0 from an array

  1. #1
    Registered User
    Join Date
    06-21-2007
    Posts
    14

    retrieving values which are not 0 from an array

    hi!
    i tried to use lookup to retrieve values from an array, but i could not define the lookup value using criteria (">0").

    example: 0 0 0 0 34 0 25
    the result that i want: 34 25

    any idea? thanks in advance!!

  2. #2
    Forum Expert
    Join Date
    09-09-2005
    Location
    England
    MS-Off Ver
    2007
    Posts
    1,500
    what do you need the results for? Just a list in seperate cells or an array

    what iis the end result you need?

    Can you provide more information?

    Regards

    Dav

  3. #3
    Registered User
    Join Date
    06-21-2007
    Posts
    14
    i would like to retrieve the values from an array (several columns and rows) which are matched certain criteria (i.e. >0), and i want to get the result in one row (several columns, depend on the number of values that have been found).

    i hope i make this problem clear...

  4. #4
    Forum Expert
    Join Date
    09-09-2005
    Location
    England
    MS-Off Ver
    2007
    Posts
    1,500
    Well you either have to do a complicated formula or write a simple macro, I choose the later. If you put the data on the sheet attached then click on the button, it will ask you for the range of data eg a1:c4 and then the cell you wish your rows to start in

    Regards

    Dav
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    06-21-2007
    Posts
    14
    thanks a lot Dav!!
    it works fine and i can modify it for my current need.

  6. #6
    Registered User
    Join Date
    06-21-2007
    Posts
    14
    Last week I got help to solve the problem to retrieve non zero values from an array into one row (see previous msg). I use the macro result for further calculation. It turns out that everytime I run the macro, it creates #REF in the calculation that refers to the macro result. Actually I will not get the #REF error with (further calculation of) the result of the macro only, I will only get it when I link my previous calculation and run the macro. A bit confusing to explain, so I also attach the working sheet where the problem occurs.

    Thanks in advance.

    Adeina
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    06-21-2007
    Posts
    14
    Sorry, did not include the macro in the example in the previous post.

    Adeina
    Attached Files Attached Files

+ 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