Click here to Skip to main content
16,005,316 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: What compiler do the pros use? Pin
Chris Losinger25-Feb-03 13:53
professionalChris Losinger25-Feb-03 13:53 
GeneralRe: What compiler do the pros use? Pin
Anonymous25-Feb-03 13:58
Anonymous25-Feb-03 13:58 
GeneralRe: What compiler do the pros use? Pin
Chris Losinger25-Feb-03 14:59
professionalChris Losinger25-Feb-03 14:59 
AnswerRe: What compiler do the pros use? Pin
Todd Smith25-Feb-03 14:42
Todd Smith25-Feb-03 14:42 
GeneralRe: What compiler do the pros use? Pin
ROK_RShadow25-Feb-03 19:28
ROK_RShadow25-Feb-03 19:28 
GeneralRe: What compiler do the pros use? Pin
Christian Graus25-Feb-03 20:02
protectorChristian Graus25-Feb-03 20:02 
GeneralRe: What compiler do the pros use? Pin
peterchen25-Feb-03 22:09
peterchen25-Feb-03 22:09 
Generalretreive handel Pin
aguest25-Feb-03 12:53
aguest25-Feb-03 12:53 
hello,
i have problem with my application ,because my application must give the handel and name in the titlebare of the windows who was active ,
but it give me only the name on the title bar of my application.
i can't find the problem can you helm meFrown | :(


'code'
#include<windows.h>
#include"resource.h"
#include<winuser.h>

char Buffer[256];


int CALLBACK EnumWindowsProc(HWND handel, LPARAM lparam);
HWND handel;



int CALLBACK DlgProc(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam)
{

switch(Msg)
{
case WM_COMMAND:

switch(LOWORD(wParam))
{
case IDC_BOUTON:

EnumWindows(&EnumWindowsProc,lParam);


return TRUE;
}
return FALSE;


case WM_CLOSE:
DestroyWindow(hWnd);

return TRUE;

}
return FALSE;
}



BOOL CALLBACK EnumWindowsProc(HWND handel,LPARAM lParam)
{

if( IsWindowVisible(handel) /*|| IsIconic(hWnd)*/)
//You try to keep the condition IsIconic & check the different
{

//------- Show handle & Caption of windows---
GetWindowText(handel, Buffer, 256);
if(strlen(Buffer)== 0 )
strcat(Buffer , "Empty");
//printf("%d\t%s\n",hwnd,Buffer);
SetDlgItemText(handel,IDC_EDIT1,Buffer);



//-------------------------------------------
}
return true;
}



int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE, LPSTR cmdLine, int)
{
return DialogBox(hInstance,(LPCTSTR)IDD_MAIN,NULL,(DLGPROC)DlgProc);
}

'code'
GeneralRe: retreive handel Pin
Hans Ruck25-Feb-03 21:44
Hans Ruck25-Feb-03 21:44 
GeneralRe: retreive handel Pin
aguest26-Feb-03 2:14
aguest26-Feb-03 2:14 
GeneralDeny Time/Date change Pin
Presup25-Feb-03 12:47
Presup25-Feb-03 12:47 
GeneralRe: Deny Time/Date change Pin
Chris Losinger25-Feb-03 13:55
professionalChris Losinger25-Feb-03 13:55 
GeneralRe: Deny Time/Date change Pin
Presup1-Mar-03 18:29
Presup1-Mar-03 18:29 
GeneralRe: Deny Time/Date change Pin
peterchen25-Feb-03 22:25
peterchen25-Feb-03 22:25 
GeneralRe: Deny Time/Date change Pin
Presup1-Mar-03 18:31
Presup1-Mar-03 18:31 
General'=' operator with a list of args on the RHS Pin
Anton A. Loukine25-Feb-03 12:08
Anton A. Loukine25-Feb-03 12:08 
GeneralRe: '=' operator with a list of args on the RHS Pin
Tim Smith25-Feb-03 12:41
Tim Smith25-Feb-03 12:41 
GeneralRe: '=' operator with a list of args on the RHS Pin
Michael Dunn25-Feb-03 12:43
sitebuilderMichael Dunn25-Feb-03 12:43 
GeneralLarge fonts causing a ghost background Pin
Brigg Thorp25-Feb-03 10:10
Brigg Thorp25-Feb-03 10:10 
General[Beta-tester search] Test System Information Viewer Pin
Dominik Reichl25-Feb-03 8:50
Dominik Reichl25-Feb-03 8:50 
GeneralRe: [Beta-tester search] Test System Information Viewer Pin
Neville Franks25-Feb-03 9:40
Neville Franks25-Feb-03 9:40 
GeneralRe: [Beta-tester search] Test System Information Viewer Pin
Dominik Reichl26-Feb-03 1:16
Dominik Reichl26-Feb-03 1:16 
GeneralRe: [Beta-tester search] Test System Information Viewer Pin
Anders Molin25-Feb-03 12:26
professionalAnders Molin25-Feb-03 12:26 
GeneralRe: [Beta-tester search] Test System Information Viewer Pin
Dominik Reichl26-Feb-03 1:17
Dominik Reichl26-Feb-03 1:17 
Generalan odd problem Pin
ns25-Feb-03 8:07
ns25-Feb-03 8:07 

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.