Click here to Skip to main content
15,889,281 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: load bitmapfile on dialog at runtime.. Pin
Jijo.Raj11-Jan-04 18:45
Jijo.Raj11-Jan-04 18:45 
GeneralRe: load bitmapfile on dialog at runtime.. Pin
swarnamanoo11-Jan-04 20:08
swarnamanoo11-Jan-04 20:08 
GeneralRe: load bitmapfile on dialog at runtime.. Pin
Ryan Binns11-Jan-04 20:49
Ryan Binns11-Jan-04 20:49 
GeneralRe: load bitmapfile on dialog at runtime.. Pin
Jijo.Raj11-Jan-04 20:55
Jijo.Raj11-Jan-04 20:55 
GeneralRe: load bitmapfile on dialog at runtime.. Pin
swarnamanoo12-Jan-04 0:37
swarnamanoo12-Jan-04 0:37 
Generalclose window explorer by my application Pin
Member 80599911-Jan-04 16:48
Member 80599911-Jan-04 16:48 
GeneralRe: close window explorer by my application Pin
SiddharthAtw11-Jan-04 19:15
SiddharthAtw11-Jan-04 19:15 
GeneralRe: close window explorer by my application Pin
Jijo.Raj11-Jan-04 19:21
Jijo.Raj11-Jan-04 19:21 
please try this method. Big Grin | :-D

1. First get the list of all process in the system. Use the function - CreateToolhelp32Snapshot ().

2. Then traverse through the list by using Process32First() and Process32Next using structure PROCESSENTRY32.

3. Then by traversing find the process of the windows explorer. User "szExeFile" member of PROCESSENTRY32 structure for Identifing the Process of explorer. Its the "path + filename" of the exe of the process. For us the path of explorer is - Get the value of the environment variable - <windir> + "explorer.exe". Because explorer.exe lies in the windows system folder.

4. Now get the handle of the explorer process using the OpenProcess () function. Pass the PROCESSENTRY32.th32ProcessID as the dwProcessId parameter of the OpenProcess () function. Now you get the handle as the return of the OpenProcess () function.

5. Now you got the handle. The rest is simple - Call TerminateProcess () function using the handle and the process will get terminated.

simple. isn't it ? Wink | ;)

NB: Read thoroughly about each and every function ur using for this in MSDN. Many of the function are asking the privilage you need when you play on processes. So if you dont have necessery privilage, the Termination wont work.

Regards,
Jijo. Wink | ;)

________________________________

Yesterday is history,
Tomorrow is a mystery,
But today is a present.
Generalconverting from a string to an int/float using Win32 locale functions Pin
Jim Crafton11-Jan-04 14:49
Jim Crafton11-Jan-04 14:49 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
bryce11-Jan-04 15:28
bryce11-Jan-04 15:28 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
Christian Graus11-Jan-04 15:50
protectorChristian Graus11-Jan-04 15:50 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
l a u r e n11-Jan-04 16:10
l a u r e n11-Jan-04 16:10 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
Christian Graus11-Jan-04 16:13
protectorChristian Graus11-Jan-04 16:13 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
Jim Crafton11-Jan-04 16:22
Jim Crafton11-Jan-04 16:22 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
Christian Graus11-Jan-04 16:39
protectorChristian Graus11-Jan-04 16:39 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
Jim Crafton11-Jan-04 16:59
Jim Crafton11-Jan-04 16:59 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
Jim Crafton11-Jan-04 16:24
Jim Crafton11-Jan-04 16:24 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
Christian Graus11-Jan-04 16:40
protectorChristian Graus11-Jan-04 16:40 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
Jim Crafton11-Jan-04 17:01
Jim Crafton11-Jan-04 17:01 
GeneralRe: converting from a string to an int/float using Win32 locale functions Pin
David Crow12-Jan-04 5:34
David Crow12-Jan-04 5:34 
GeneralDownload a web page Pin
Daniel132411-Jan-04 14:44
Daniel132411-Jan-04 14:44 
GeneralRe: Download a web page Pin
Roger Wright11-Jan-04 15:17
professionalRoger Wright11-Jan-04 15:17 
GeneralRe: Download a web page Pin
Daniel132411-Jan-04 15:19
Daniel132411-Jan-04 15:19 
GeneralRe: Download a web page Pin
bryce11-Jan-04 15:30
bryce11-Jan-04 15:30 
GeneralRe: Download a web page Pin
Daniel132411-Jan-04 15:41
Daniel132411-Jan-04 15:41 

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.