+ Reply to Thread
Results 1 to 4 of 4

Type Mismatch Error when I highlight multiple cells and use the delete key

  1. #1
    Registered User
    Join Date
    06-15-2012
    Location
    Pennsylvania, USA
    MS-Off Ver
    Excel 2010
    Posts
    46

    Type Mismatch Error when I highlight multiple cells and use the delete key

    When I highlight multiple cells, and use the delet key on my keyboard I get the following error

    Run-time error "13"
    type mismatch


    This is the code I have in my workbook, the portion in red below is where the issue is per when i hit the debug option on the error msg box. I hope someone has the right answer to this out there, thanks in advance for the help.

    Please Login or Register  to view this content.

  2. #2
    Valued Forum Contributor StevenM's Avatar
    Join Date
    03-23-2008
    Location
    New Lenox, IL USA
    MS-Off Ver
    2007
    Posts
    910

    Re: Type Mismatch Error when I highlight multiple cells and use the delete key

    Target is a range. When you change multiple cells at once, then Target is a range of cells. I don't know what you are trying to do, so I don't know how to change it. Depending on what you want, you could try: If Target.Cells(1, 1) <> "" Then etc.

  3. #3
    Registered User
    Join Date
    06-15-2012
    Location
    Pennsylvania, USA
    MS-Off Ver
    Excel 2010
    Posts
    46

    Re: Type Mismatch Error when I highlight multiple cells and use the delete key

    The purpose of the Macro is that whenever there is a chnage in the workbook, any cell at all in the workbook, then I would like the button to the enabled to run another macro that is attached to the button. However when I delete multiple cells at once I get that error. Is there a way to write the macro to accommodate that?

  4. #4
    Valued Forum Contributor StevenM's Avatar
    Join Date
    03-23-2008
    Location
    New Lenox, IL USA
    MS-Off Ver
    2007
    Posts
    910

    Re: Type Mismatch Error when I highlight multiple cells and use the delete key

    What about?

    Please Login or Register  to view this content.

+ 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