+ Reply to Thread
Results 1 to 3 of 3

Iserror is giving me a type mismatch

  1. #1
    Registered User
    Join Date
    12-26-2011
    Location
    San Francisco
    MS-Off Ver
    Excel 2010
    Posts
    45

    Iserror is giving me a type mismatch

    I want to run a For Loop only if the calculation doesn't give me an error. here is the code fragment that is not working along with the declarations:

    Please Login or Register  to view this content.
    RowKey is a String
    HardcodeKey is a Variant
    LookUpRange String

    It passes when RowKey is found but fails when it is not it gives me the error, "Type Mismatch"

  2. #2
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,474

    Re: Iserror is giving me a type mismatch

    Could you attach a sample workbook?

  3. #3
    Registered User
    Join Date
    12-26-2011
    Location
    San Francisco
    MS-Off Ver
    Excel 2010
    Posts
    45

    Re: Iserror is giving me a type mismatch

    Hi Dave, sorry to waste your time, I solved this by changing RowKey to a variant. Also, my example above should not have put "RowKey =" in the formula.

+ 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