+ Reply to Thread
Results 1 to 5 of 5

Match function to return column number for matching date errors

  1. #1
    Registered User
    Join Date
    08-08-2013
    Location
    Texas
    MS-Off Ver
    Excel 2010
    Posts
    46

    Match function to return column number for matching date errors

    Hello All,

    I am trying to use some vba match function code to return the column number of the matching date. The date will be stored in a date variable.

    Every time I run this code I normally get a match error even though the date is in the worksheet and the variable matches that date.

    See below:
    Please Login or Register  to view this content.

    Thanks

  2. #2
    Forum Contributor mongoose36's Avatar
    Join Date
    06-10-2013
    Location
    Lincoln
    MS-Off Ver
    Excel 2013
    Posts
    389

    Re: Match function to return column number for matching date errors

    See Below



    Please Login or Register  to view this content.
    Last edited by mongoose36; 08-06-2014 at 11:21 AM.
    If your questions has been answered to your satisfaction please don't forget to do the following:

    Add Reputation ... and ... Mark Thread as Solved

    Thanks,

    Ma 10:8b Freely you have received; freely give.

  3. #3
    Forum Expert
    Join Date
    07-31-2010
    Location
    California
    MS-Off Ver
    Excel 2007
    Posts
    4,070

    Re: Match function to return column number for matching date errors

    You are going to run into multiple issues with the use of Long versus variant and then error checking against the match. In addition, the date formats combined with the inputbox and trying to get them the same to be recognized by .Match can be troublesome at times. I suggest doing something like this which in your case should be just as fast:

    Please Login or Register  to view this content.

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

    Re: Match function to return column number for matching date errors

    Try change to
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    08-08-2013
    Location
    Texas
    MS-Off Ver
    Excel 2010
    Posts
    46

    Re: Match function to return column number for matching date errors

    Thank you guys,

    Jindon found exactly what I was looking for. Thanks!

    M

  6. #6
    Registered User
    Join Date
    08-08-2013
    Location
    Texas
    MS-Off Ver
    Excel 2010
    Posts
    46

    Re: Match function to return column number for matching date errors

    Thank you guys,

    Jindon found exactly what I was looking for. Thanks!

    M

+ 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. Replies: 3
    Last Post: 01-03-2014, 08:03 PM
  2. Replies: 1
    Last Post: 02-21-2013, 05:49 PM
  3. [SOLVED] Formula to match data ( multi column) in different sheets and return matching values
    By kangyao in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 01-17-2013, 08:49 PM
  4. [SOLVED] Formula to match data in different sheets ( multi column) and return matching values
    By kangyao in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-11-2013, 07:38 PM
  5. Replies: 4
    Last Post: 02-11-2011, 08:59 AM

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