Click here to Skip to main content
16,004,854 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionRe: Using GROUP BY Clause in CRecordset::Open() Pin
David Crow10-May-07 2:02
David Crow10-May-07 2:02 
Questionuse of undefined struct Pin
subramanyeswari9-May-07 21:28
subramanyeswari9-May-07 21:28 
QuestionRe: use of undefined struct Pin
CPallini9-May-07 22:21
mveCPallini9-May-07 22:21 
QuestionRe: use of undefined struct Pin
subramanyeswari10-May-07 0:01
subramanyeswari10-May-07 0:01 
Questionhow to create an Activex Exe in Vc++ Pin
ggdfgdfg9-May-07 21:23
ggdfgdfg9-May-07 21:23 
AnswerRe: how to create an Activex Exe in Vc++ Pin
Rajesh R Subramanian9-May-07 21:30
professionalRajesh R Subramanian9-May-07 21:30 
AnswerRe: how to create an Activex Exe in Vc++ Pin
Hamid_RT9-May-07 22:29
Hamid_RT9-May-07 22:29 
QuestionExtract Icon Pin
Programm3r9-May-07 20:38
Programm3r9-May-07 20:38 
Hi all,

I have developed a win32 console application, that has a notify icon in the taskbar. The problem is that I'm using the file name to load the icon, so if the ico file is not present, the icon can not be loaded.
For example:
...
    niData.uFlags = NIF_ICON|NIF_MESSAGE|NIF_TIP;

    LPTSTR szFileName = "SlotClient.ico";
	
    niData.hIcon = (HICON)LoadImage( NULL,
					szFileName,
					IMAGE_ICON,
					0,
					0,
					LR_CREATEDIBSECTION | LR_DEFAULTSIZE | LR_LOADFROMFILE );

	strcpy(niData.szTip,"Application Running");
	SetConsoleTitle((LPCSTR)"Test Application"); 
	HWND hWnd = FindWindow(NULL, (LPCTSTR)"Test Application");
	niData.hWnd = hWnd;

	BOOL rc = Shell_NotifyIcon(NIM_ADD,&niData);
...


Q:How can I load an icon out of the dynamic link library 'user32.dll' so that when I can't find the .ico, I can load another one from the dll.

Many Thanks.
Regards,


The only programmers that are better than C programmers are those who code in 1's and 0's..... Smile | :)

Smile | :) Programm3r

My Blog: ^_^

AnswerRe: Extract Icon Pin
Hans Dietrich9-May-07 21:11
mentorHans Dietrich9-May-07 21:11 
AnswerRe: Extract Icon Pin
Paresh Chitte9-May-07 21:18
Paresh Chitte9-May-07 21:18 
QuestionRe: Extract Icon Pin
Programm3r9-May-07 21:32
Programm3r9-May-07 21:32 
AnswerRe: Extract Icon Pin
Stephen Hewitt9-May-07 21:58
Stephen Hewitt9-May-07 21:58 
GeneralRe: Extract Icon Pin
Programm3r9-May-07 22:21
Programm3r9-May-07 22:21 
QuestionExtract Icon - nIconIndex ?? [modified] Pin
Programm3r9-May-07 22:50
Programm3r9-May-07 22:50 
AnswerRe: Extract Icon - nIconIndex ?? Pin
Programm3r9-May-07 23:22
Programm3r9-May-07 23:22 
Questionre:Draging Image over dialogBox Pin
rjkg9-May-07 20:23
rjkg9-May-07 20:23 
AnswerRe: re:Draging Image over dialogBox Pin
ThatsAlok16-May-07 21:10
ThatsAlok16-May-07 21:10 
QuestionPDF Viewer ActiveX Control Pin
Midhun_M9-May-07 19:46
Midhun_M9-May-07 19:46 
AnswerRe: PDF Viewer ActiveX Control Pin
Programm3r9-May-07 19:56
Programm3r9-May-07 19:56 
QuestionRe: PDF Viewer ActiveX Control Pin
Midhun_M9-May-07 23:32
Midhun_M9-May-07 23:32 
QuestionCopy Constructor Pin
ragavan9-May-07 19:31
ragavan9-May-07 19:31 
AnswerRe: Copy Constructor Pin
Stephen Hewitt9-May-07 19:40
Stephen Hewitt9-May-07 19:40 
AnswerRe: Copy Constructor Pin
Nemanja Trifunovic10-May-07 1:30
Nemanja Trifunovic10-May-07 1:30 
AnswerRe: Copy Constructor Pin
ThatsAlok16-May-07 21:10
ThatsAlok16-May-07 21:10 
QuestionRun an exe Pin
saisp9-May-07 19:13
saisp9-May-07 19:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.