Consulting

Results 1 to 6 of 6

Thread: Structure of the array that is returned by ClipboardFormats

  1. #1
    VBAX Newbie
    Joined
    Sep 2007
    Location
    Europe, Estonia, Maardu
    Posts
    3
    Location

    Structure of the array that is returned by ClipboardFormats

    Hi!

    It's known, that Windows puts into clipboard a few formats,
    that we can get by Application.ClipboardFormats.

    But what means the value starting from 44 and often 50
    as values of the last members of the array?
    For example, if we copy the some text from Notepad and
    after that examinate the result array we'll see the two members
    with values 0 and 44.

  2. #2
    Knowledge Base Approver VBAX Master Oorang's Avatar
    Joined
    Jan 2007
    Posts
    1,135
    Location
    0 is xlClipboardFormatText I haven't ever seen 44 or 50 (can't dig them up either). At first I thought it might be a combination of two flags but the enum is sequential and does not appear to be using bit flags.
    Cordially,
    Aaron



    Keep Our Board Clean!
    • Please Mark your thread "Solved" if you get an acceptable response (under thread tools).
    • Enclose your code in VBA tags then it will be formatted as per the VBIDE to improve readability.

  3. #3
    VBAX Newbie
    Joined
    Sep 2007
    Location
    Europe, Estonia, Maardu
    Posts
    3
    Location
    Hi, Oorang!
    Thank you for reply.
    The first picture shows array values for data that has been copied from Notepad.

  4. #4
    VBAX Newbie
    Joined
    Sep 2007
    Location
    Europe, Estonia, Maardu
    Posts
    3
    Location
    The second picture shows array values for data copied from screen that shows your reply. Just wondering what do these values (44,50 and similar, that not in range of the xlClipboardFormat values) mean.
    (Excel 2003/Windows XP)

  5. #5
    VBAX Master
    Joined
    Jun 2007
    Location
    East Sussex
    Posts
    1,110
    Location
    I can only guess that they are some sort of internal code which is not exposed to us mere mortals. (44 seems to appear with everything I copy in my tests). There is nothing useful you can do with them anyway as far as I can tell.
    Regards,
    Rory

    Microsoft MVP - Excel

  6. #6
    Knowledge Base Approver VBAX Master Oorang's Avatar
    Joined
    Jan 2007
    Posts
    1,135
    Location
    Hmm give this a read:
    http://msdn2.microsoft.com/en-us/lib...pboard_Formats

    I gave GetClipboardFormatNameA Sub a shot, but I still pulls back nothing, I surmise either A 44 is a private format. B The values in Application.ClipboardFormats do not directly correspond to the values used by the clipboard API.
    Cordially,
    Aaron



    Keep Our Board Clean!
    • Please Mark your thread "Solved" if you get an acceptable response (under thread tools).
    • Enclose your code in VBA tags then it will be formatted as per the VBIDE to improve readability.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •