Click here to Skip to main content
13,355,093 members (58,573 online)
Click here to Skip to main content
Articles » Multimedia » GDI » General » Downloads


93 bookmarked
Posted 11 Jan 2003

Barry's Screen Capture

, 11 Jan 2003
An article showing methods of screen capture
#if !defined(AFX_MYTRAYICON_H__0E474F41_F007_11D6_A702_C99C0CE4946C__INCLUDED_)
#define AFX_MYTRAYICON_H__0E474F41_F007_11D6_A702_C99C0CE4946C__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// MyTrayIcon.h : header file

// CMyTrayIcon command target

class CMyTrayIcon : public CCmdTarget

	CMyTrayIcon();           // protected constructor used by dynamic creation
	NOTIFYICONDATA m_nid;			// struct for Shell_NotifyIcon args

// Attributes

// Operations
	// Call this to receive tray notifications
	void SetNotificationWnd(CWnd* pNotifyWnd, UINT uCbMsg);

	// SetIcon functions. To remove icon, call SetIcon(0)
	BOOL SetIcon(UINT uID); // main variant you want to use
	BOOL SetIcon(HICON hicon, LPCSTR lpTip);
	BOOL SetIcon(LPCTSTR lpResName, LPCSTR lpTip)
		{ return SetIcon(lpResName ? 
			AfxGetApp()->LoadIcon(lpResName) : NULL, lpTip); }
	BOOL SetStandardIcon(LPCTSTR lpszIconName, LPCSTR lpTip)
		{ return SetIcon(::LoadIcon(NULL, lpszIconName), lpTip); }

	virtual LRESULT OnTrayNotification(WPARAM uID, LPARAM lEvent);

// Overrides
	// ClassWizard generated virtual function overrides

// Implementation
//	virtual ~CMyTrayIcon();

	// Generated message map functions
		// NOTE - the ClassWizard will add and remove member functions here.



// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_MYTRAYICON_H__0E474F41_F007_11D6_A702_C99C0CE4946C__INCLUDED_)

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.


This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


About the Author

Barretto VN
India India
Nothing to boast about

You may also be interested in...

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.180111.1 | Last Updated 12 Jan 2003
Article Copyright 2003 by Barretto VN
Everything else Copyright © CodeProject, 1999-2018
Layout: fixed | fluid