+ Reply to Thread
Results 1 to 3 of 3

Type Mismatch Error 13

  1. #1
    Registered User
    Join Date
    01-18-2010
    Location
    Nova Scotia, Canada
    MS-Off Ver
    Excel 2003
    Posts
    68

    Type Mismatch Error 13

    Hello all...
    I'm trying to write a pretty simple macro which invokes a built-in DDE function to retrieve some data, then when the data is retrieved, just show a msgbox. When the data is finished being retrieved, cell(20,11) in the sheet "Historical Data" will automatically have "FINISHED" placed in it. So while the retrieval is taking place, I'm simply looping and checking the contents of this cell waiting for it to read "FINISHED". My problem is the
    'Do While Sheets("Historical Data").Cells(20, 11) <> "FINISHED"' line generates a "Type Mismatch Runtime Error 13", which I can't for the life of me understand why. Can anyone shed any light please?


    Please Login or Register  to view this content.

    Thanks!
    Shawn

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Type Mismatch Error 13

    Hello Shawn,

    The DDE link is probably saving non string data in cell. I modified your macro to first check if the data in the cell is string and if it is then check for the word "FINISHED".
    Please Login or Register  to view this content.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    01-18-2010
    Location
    Nova Scotia, Canada
    MS-Off Ver
    Excel 2003
    Posts
    68

    Re: Type Mismatch Error 13

    That worked GREAT Leith... this is gonna change my life! Thanks so much.

    Cheers
    Shawn

+ 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