Jump to content

WinCloseClipbrd: Difference between revisions

From EDM2
Ak120 (talk | contribs)
mNo edit summary
No edit summary
 
Line 5: Line 5:


==Parameters==
==Parameters==
;hab (HAB) - input: Anchor-block handle.
;''hab'' (HAB) - input: Anchor-block handle.


==Returns==
==Returns==
;rc (BOOL) - returns:Success indicator.
;''rc'' (BOOL) - returns:Success indicator.
::TRUE :Successful completion
::TRUE :Successful completion
::FALSE :Error occurred.
::FALSE :Error occurred.
Line 30: Line 30:


==Related Functions==
==Related Functions==
* WinEmptyClipbrd
* [[WinEmptyClipbrd]]
* WinEnumClipbrdFmts
* [[WinEnumClipbrdFmts]]
* WinOpenClipbrd
* [[WinOpenClipbrd]]
* WinQueryClipbrdData
* [[WinQueryClipbrdData]]
* WinQueryClipbrdFmtInfo
* [[WinQueryClipbrdFmtInfo]]
* WinQueryClipbrdOwner
* [[WinQueryClipbrdOwner]]
* WinQueryClipbrdViewer
* [[WinQueryClipbrdViewer]]
* WinSetClipbrdData
* [[WinSetClipbrdData]]
* WinSetClipbrdOwner
* [[WinSetClipbrdOwner]]
* WinSetClipbrdViewer
* [[WinSetClipbrdViewer]]


==Related Messages==
==Related Messages==
* WM_DRAWCLIPBOARD
* [[WM_DRAWCLIPBOARD]]


[[Category:Win]]
[[Category:Win]]

Latest revision as of 19:02, 10 April 2025

This function closes the clipboard, allowing other applications to open it with the WinOpenClipbrd function.

Syntax

WinCloseClipbrd(hab)

Parameters

hab (HAB) - input
Anchor-block handle.

Returns

rc (BOOL) - returns
Success indicator.
TRUE :Successful completion
FALSE :Error occurred.

Remarks

This function causes the contents of the clipboard to be drawn in the clipboard viewer window (if any), by sending it a WM_DRAWCLIPBOARD message. This action occurs only if the clipboard data has changed.

The clipboard must be open before this function is invoked.

Example Code

This example closes the clipboard, previously opened by WinOpenClipbrd, to allow other applications to open it for use.

#define INCL_WINCLIPBOARD       /* Window Clipboard Functions   */
#include <os2.h>

BOOL  fSuccess;         /* success indicator                    */
HAB   hab;              /* anchor-block handle                  */

fSuccess = WinCloseClipbrd(hab);

Related Functions

Related Messages