This example calls the DrgQueryDragitemCount function to return the number of DRAGITEM structures in the corresponding DRAGINFO structure, which maps to the number of objects being dragged.
#define INCL_WINSTDDRAG /* Direct Manipulation (Drag) Functions */ #include <os2.h> ULONG cDitem; /* Number of objects being dragged */ DRAGINFO Draginfo; /* DRAGINFO structure queried for the */ /* number of drag objects */ cDitem = DrgQueryDragitemCount(&Draginfo);