Results 1 to 3 of 3

On Error Resume Next not working

Threaded View

  1. #1
    Registered User
    Join Date
    08-29-2018
    Location
    Barnsley
    MS-Off Ver
    Office 2013
    Posts
    4

    On Error Resume Next not working

    I have the following snippet of my code where the On Error Resume Next is not working if the user inadvertently copies an image into the clipboard.

    I just get the error message: Run-time error '-2147221404 (80040064)': DataObject:GetText Invalid FORMATETC structure

    I just need to be able to skip the error but can't seem to find an answer if anyone can help please.

    Dim dataObj As MSForms.DataObject
    Dim strPaste As string

    Set dataObj = New MSForms.DataObject
    dataObj.GetFromClipboard

    On Error Resume Next
    strPaste = dataObj.GetText
    Last edited by pcsparky; 06-19-2019 at 07:12 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Runtime Error 53 On error resume next not working
    By KevBotes in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-01-2016, 11:07 AM
  2. On Error Resume Next not working on some PC's
    By Bishonen in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-29-2015, 12:05 PM
  3. [SOLVED] VBA help needed to capture Error and Remove Pivot if error exist else resume
    By Tescatlipoca in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-18-2014, 05:46 PM
  4. [SOLVED] Need Resume and ErrorHandler added to working code
    By mc84excel in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-06-2013, 10:02 PM
  5. [SOLVED] resume next not working
    By foxguy in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-11-2012, 12:50 PM
  6. Resume Next not working
    By foxguy in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-17-2010, 11:26 AM
  7. "on error resume next" NOT working...
    By Chris M in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-13-2005, 06:05 PM

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