This example obtains a handle to the current clipboard data of text format if that format is present in the clipboard.

#define INCL_WINCLIPBOARD
#include <OS2.H>

HAB hab;

ULONG  format;
ULONG hclipbrdData;

if (WinQueryClipbrdData(hab,CF_TEXT))
   {
    hclipbrdData = WinQueryClipbrdFmfInfo(hab,
                                          CF_TEXT
                                          &format);
   }


[Back] [Next]