Click here to Skip to main content
15,921,716 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralReceive LVN_BEGINDRAG in parent dialog of CListCtrl, but no LVN_ENDDRAG Pin
followait5-Dec-07 21:25
followait5-Dec-07 21:25 
Generalyyuuyuu Pin
vghh5-Dec-07 21:16
sussvghh5-Dec-07 21:16 
General16 bit image using Bitmap or TIFF using VC++ (MFC control) Pin
sunny.rana5-Dec-07 21:10
sunny.rana5-Dec-07 21:10 
GeneralRe: 16 bit image using Bitmap or TIFF using VC++ (MFC control) Pin
CPallini5-Dec-07 21:38
mveCPallini5-Dec-07 21:38 
GeneralInternet Printing Pin
Rajeev Verma5-Dec-07 20:48
Rajeev Verma5-Dec-07 20:48 
GeneralRe: Internet Printing Pin
Nelek5-Dec-07 22:56
protectorNelek5-Dec-07 22:56 
QuestionGetWindowModuleFileName (Succeed/Failed) ? Pin
nitin35-Dec-07 20:16
nitin35-Dec-07 20:16 
AnswerRe: GetWindowModuleFileName (Succeed/Failed) ? Pin
Naveen5-Dec-07 20:43
Naveen5-Dec-07 20:43 
nitin3 wrote:
is there any other way to get the module name of an hWnd ?

Yep. the below code will do.


DWORD dwProcessId;<br />
GetWindowThreadProcessId( hWnd, &dwProcessId);<br />
HINSTANCE hModule = (HINSTANCE)GetWindowLong(hWnd, GWL_HINSTANCE);<br />
if(hModule == NULL)<br />
{<br />
  return;<br />
}<br />
HANDLE hProcess = OpenProcess(PROCESS_VM_READ|PROCESS_QUERY_INFORMATION, FALSE, dwProcessId);<br />
if( hProcess == NULL )<br />
{<br />
   return;<br />
}<br />
bool bReturn = GetModuleFileNameEx( hProcess, hModule, csLog.GetBuffer( MAX_PATH), MAX_PATH );<br />
csLog.ReleaseBuffer();


Where hWnd is the handle of any window


GeneralRe: GetWindowModuleFileNameEx (Succeeded ! ) Pin
nitin35-Dec-07 21:12
nitin35-Dec-07 21:12 
GeneralWriteFIle() to serial port. Pin
Anu_Bala5-Dec-07 20:14
Anu_Bala5-Dec-07 20:14 
GeneralRe: WriteFIle() to serial port. Pin
CPallini5-Dec-07 21:25
mveCPallini5-Dec-07 21:25 
QuestionCListCtrl : How to un-select item in the list programmatically ? Pin
xanagan6665-Dec-07 19:51
xanagan6665-Dec-07 19:51 
AnswerRe: CListCtrl : How to un-select item in the list programmatically ? Pin
Naveen5-Dec-07 20:50
Naveen5-Dec-07 20:50 
QuestionHow do I detect the audio/video capabilities on machine Pin
jit_knit5-Dec-07 18:45
jit_knit5-Dec-07 18:45 
GeneralSaving PowerpointSlide as Bitmap From a Win32 Api based Application Pin
niloy5-Dec-07 18:20
niloy5-Dec-07 18:20 
Questionabout pdf library. Pin
keyto5-Dec-07 18:12
keyto5-Dec-07 18:12 
GeneralRe: about pdf library. Pin
Hamid_RT5-Dec-07 18:29
Hamid_RT5-Dec-07 18:29 
QuestionRe: about pdf library. Pin
keyto5-Dec-07 19:05
keyto5-Dec-07 19:05 
GeneralFill CListCtrl with Images, about 20 images, performance problem Pin
followait5-Dec-07 17:09
followait5-Dec-07 17:09 
GeneralRe: Fill CListCtrl with Images, about 20 images, performance problem Pin
Hamid_RT5-Dec-07 18:28
Hamid_RT5-Dec-07 18:28 
GeneralRe: Fill CListCtrl with Images, about 20 images, performance problem Pin
followait5-Dec-07 19:16
followait5-Dec-07 19:16 
GeneralRe: Fill CListCtrl with Images, about 20 images, performance problem Pin
Hamid_RT6-Dec-07 0:18
Hamid_RT6-Dec-07 0:18 
GeneralRe: Fill CListCtrl with Images, about 20 images, performance problem Pin
Naveen5-Dec-07 18:50
Naveen5-Dec-07 18:50 
GeneralRe: Fill CListCtrl with Images, about 20 images, performance problem Pin
followait5-Dec-07 19:15
followait5-Dec-07 19:15 
GeneralRe: Fill CListCtrl with Images, about 20 images, performance problem Pin
Hamid_RT6-Dec-07 0:18
Hamid_RT6-Dec-07 0:18 

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.