+ Reply to Thread
Results 1 to 2 of 2

Automatically insert arguments from list to function

  1. #1
    Registered User
    Join Date
    10-10-2011
    Location
    Athens,Greece
    MS-Off Ver
    Excel 2003
    Posts
    1

    Post Automatically insert arguments from list to function

    Hello,

    I have an AND / OR function in which I have at least 12-15 arguments in the form of

    OR(B5="0439";B5="0535";B5="0536";B5="0567";B5="0811";B5="0898";B5="0923";B5="0936";B5="0941";B5="0957";B5="0972")

    The arguments changes frequently and every time, I have to change them manually. I have the statements in a list in the form of
    0439
    0535
    0567
    etc

    Is there any way that I can "feed" the function automatically from the list.

    I have some basic Macro self-taught experience, so if there is a macro invlolved I can try it.

    Thank you

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,464

    Re: Automatically insert arguments from list to function

    If you have a list, you could just use COUNTIF or VLOOKUP to check if the cell contents is in the list.

    For example:

    =IF(COUNTIF(ListRange,B5)>0,"Found","Not Found")

    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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