DrgPushDraginfo
Appearance
This function gives a process access to a DRAGINFO structure.
Syntax
DrgPushDraginfo(pdinfo, hwndDest)
Parameters
- pdinfo (PDRAGINFO) - input
- Pointer to the DRAGINFO structure.
- hwndDest (HWND) - input
- Handle of the window whose process is to be given access to a DRAGINFO structure.
Returns
- rc (BOOL) - returns
- Success indicator.
- TRUE - Successful completion.
- FALSE - Error occurred.
Remarks
The receiving process is responsible for:
- Deleting the string handles in the DRAGINFO structure with DrgDeleteDraginfoStrHandles
- Freeing the DRAGINFO structure using DrgFreeDraginfo.
Errors
Possible returns from WinGetLastError:
- PMERR_ACCESS_DENIED (0x150D)
- The memory block was not allocated properly.
- PMERR_INSUFFICIENT_MEMORY (0x203E)
- The operation terminated through insufficient memory.
Example Code
#define INCL_WINSTDDRAG /* Direct Manipulation (Drag) Functions */ #include <os2.h> BOOL fSuccess; /* Indicate success or failure */ DRAGINFO Draginfo; /* Pointer to DRAGINFO structure */ HWND hwndDest; /* Handle of window whose process will */ /* will be given access to the DRAGINFO */ /* structure */ fSuccess = DrgPushDraginfo(&Draginfo,hwndDest);