+ Reply to Thread
Results 1 to 2 of 2

Makro with if condition to check for numeric and text values in a cell range

  1. #1
    Registered User
    Join Date
    04-13-2013
    Location
    Geneva, Switzerland
    MS-Off Ver
    Excel 2007
    Posts
    29

    Makro with if condition to check for numeric and text values in a cell range

    Hello,

    After watching some VBA tutorials on youtube, I am sure this is far above my Excel skills. Therefore, I will put it out there for anyone who has the skills and the kindness to help.

    This is what I would like the makro to do:

    - all cells in range F7:F36 are empty (=no numeric value), leave cell A5 EMPTY
    - any cell in F7:F36 has a positive numeric value, go to G column and check for same row (meaning if F7 has a number, than check G7, F8, check G8 aso)
    - the range G7:G36 contains text provided within in a drop-down list, per default the cells will be empty, unless user opens the drop-down and chooses a currency
    - the warning "choose currency" should pop up in cell A5 if any cell in the F-range contains a value, but no corresponding input is in the matching G-cell
    - if there is a matching value (user typed in an amount in e.g. F7 and chose currency in G7) than A5 should be empty again, because no warning text will be needed
    - of course, if there are five inputs in F7:F36 (e.g. first five rows) than the matching five G-cells need to have a value too; hence, whenever there is an input missing, the warning should show in A5

    I opened a thread for this one before, and got this formula from a helpful person in the Netherlands. Unfortunately its just doing half the trick. So, I assume that a Makro will be needed.

    =IF(AND(COUNT(F7:F36)>0,COUNT(G7:G36)*>0),"","CHOOSE*CURRENCY!")*

    Thanks everybody for spending your time helping me to build an awesome Travel Expense Sheet that will make many people happy!

    Cheers,
    Kim

  2. #2
    Registered User
    Join Date
    04-13-2013
    Location
    Geneva, Switzerland
    MS-Off Ver
    Excel 2007
    Posts
    29

    Re: Makro with if condition to check for numeric and text values in a cell range

    Hi,

    I just got another formula from the nice person in the Netherlands!

    This time it works great. *happy*

    Thanks everybody!
    /Kim

+ 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