Click here to Skip to main content
11,709,220 members (36,601 online)

ATL / WTL / STL

 
Questioncopying AAComBSTR to BYTE Pin
V K 220-Nov-12 20:56
memberV K 220-Nov-12 20:56 
AnswerRe: copying AAComBSTR to BYTE Pin
Richard MacCutchan20-Nov-12 21:28
mvpRichard MacCutchan20-Nov-12 21:28 
AnswerRe: copying AAComBSTR to BYTE Pin
hacker240union22-Nov-12 23:27
memberhacker240union22-Nov-12 23:27 
QuestionC++ Delegate/Events Pin
Edward G Dana14-Nov-12 17:15
memberEdward G Dana14-Nov-12 17:15 
AnswerRe: C++ Delegate/Events Pin
Richard MacCutchan14-Nov-12 20:57
mvpRichard MacCutchan14-Nov-12 20:57 
GeneralRe: C++ Delegate/Events Pin
Edward G Dana15-Nov-12 13:35
memberEdward G Dana15-Nov-12 13:35 
GeneralRe: C++ Delegate/Events Pin
Richard MacCutchan15-Nov-12 23:45
mvpRichard MacCutchan15-Nov-12 23:45 
AnswerRe: C++ Delegate/Events Pin
pasztorpisti20-Nov-12 2:53
memberpasztorpisti20-Nov-12 2:53 
GeneralRe: C++ Delegate/Events Pin
EDanaII20-Nov-12 16:23
memberEDanaII20-Nov-12 16:23 
QuestionReturn FALSE in InitInstance causes crash in 64Bits Pin
khaliloenit8-Nov-12 1:01
memberkhaliloenit8-Nov-12 1:01 
AnswerRe: Return FALSE in InitInstance causes crash in 64Bits Pin
Albert Holguin10-Dec-12 4:30
memberAlbert Holguin10-Dec-12 4:30 
QuestionHow to get used dll's path information programetically? Pin
litu kumar6-Nov-12 19:38
memberlitu kumar6-Nov-12 19:38 
AnswerRe: How to get used dll's path information programetically? Pin
Richard MacCutchan6-Nov-12 21:40
mvpRichard MacCutchan6-Nov-12 21:40 
GeneralRe: How to get used dll's path information programetically? Pin
litu kumar6-Nov-12 23:27
memberlitu kumar6-Nov-12 23:27 
Hi Richard,

You mean to initialize 'hmod' to NULL as below -


HMODULE hmod =NULL;
hmod= GetModuleHandle(TEXT("MyApp.dll"));
if(hmod!=NULL)
{
DWORD dwLen = GetModuleFileName(hmod, szPath, MAX_PATH);
wprintf(L"CURRENT DIRECTORY: %s\n" ,szPath);
}
====================================
If the above code stuff as per your indication,then 'GetModuleHandle' not returning NULL .
And it printing the path of EXE not of required 'MyApp.dll'

Kindly guide me if i understood the wrong thing.

modified 7-Nov-12 6:38am.

GeneralRe: How to get used dll's path information programetically? Pin
Richard MacCutchan7-Nov-12 4:54
mvpRichard MacCutchan7-Nov-12 4:54 
GeneralRe: How to get used dll's path information programetically? Pin
litu kumar7-Nov-12 17:11
memberlitu kumar7-Nov-12 17:11 
GeneralRe: How to get used dll's path information programetically? Pin
Richard MacCutchan7-Nov-12 21:34
mvpRichard MacCutchan7-Nov-12 21:34 
GeneralRe: How to get used dll's path information programetically? Pin
litu kumar7-Nov-12 22:35
memberlitu kumar7-Nov-12 22:35 
GeneralRe: How to get used dll's path information programetically? Pin
Richard MacCutchan8-Nov-12 0:16
mvpRichard MacCutchan8-Nov-12 0:16 
GeneralRe: How to get used dll's path information programetically? Pin
litu kumar8-Nov-12 2:58
memberlitu kumar8-Nov-12 2:58 
GeneralRe: How to get used dll's path information programetically? Pin
Richard MacCutchan8-Nov-12 4:03
mvpRichard MacCutchan8-Nov-12 4:03 
GeneralRe: How to get used dll's path information programetically? Pin
litu kumar15-Nov-12 19:53
memberlitu kumar15-Nov-12 19:53 
GeneralRe: How to get used dll's path information programetically? Pin
Richard MacCutchan15-Nov-12 23:50
mvpRichard MacCutchan15-Nov-12 23:50 
AnswerRe: How to get used dll's path information programetically? Pin
hacker240union22-Nov-12 23:41
memberhacker240union22-Nov-12 23:41 
Questiondetect close event with CAsyncSocket Pin
bkelly135-Nov-12 10:32
memberbkelly135-Nov-12 10:32 
QuestionIntermediate GUI Techniques Pin
bkelly132-Nov-12 3:21
memberbkelly132-Nov-12 3:21 
AnswerRe: Intermediate GUI Techniques Pin
Richard MacCutchan2-Nov-12 6:20
mvpRichard MacCutchan2-Nov-12 6:20 
Questionproblem with sprintf_s() on win 7 Pin
Member 93537761-Nov-12 21:34
memberMember 93537761-Nov-12 21:34 
AnswerRe: problem with sprintf_s() on win 7 Pin
Richard MacCutchan1-Nov-12 22:50
mvpRichard MacCutchan1-Nov-12 22:50 
GeneralRe: problem with sprintf_s() on win 7 Pin
bkelly132-Nov-12 3:16
memberbkelly132-Nov-12 3:16 
GeneralRe: problem with sprintf_s() on win 7 Pin
Richard MacCutchan2-Nov-12 6:15
mvpRichard MacCutchan2-Nov-12 6:15 
GeneralRe: problem with sprintf_s() on win 7 Pin
Member 93537764-Nov-12 16:34
memberMember 93537764-Nov-12 16:34 
GeneralRe: problem with sprintf_s() on win 7 Pin
Richard MacCutchan4-Nov-12 21:26
mvpRichard MacCutchan4-Nov-12 21:26 
AnswerRe: problem with sprintf_s() on win 7 Pin
H.Brydon26-Nov-12 19:36
memberH.Brydon26-Nov-12 19:36 
Questionwsageterror() Pin
bkelly131-Nov-12 15:28
memberbkelly131-Nov-12 15:28 
AnswerRe: wsageterror() Pin
Richard MacCutchan1-Nov-12 22:48
mvpRichard MacCutchan1-Nov-12 22:48 
QuestionSTL map issue in VS2010 Pin
Subhash Madhukar30-Oct-12 3:47
memberSubhash Madhukar30-Oct-12 3:47 
AnswerRe: STL map issue in VS2010 Pin
Richard MacCutchan30-Oct-12 6:04
mvpRichard MacCutchan30-Oct-12 6:04 
Questionhow do i copy a CImage DIB to clipboard Pin
Member 951640015-Oct-12 11:15
memberMember 951640015-Oct-12 11:15 
AnswerRe: how do i copy a CImage DIB to clipboard Pin
Andrew Cherednik15-Oct-12 11:41
memberAndrew Cherednik15-Oct-12 11:41 
QuestionWhy does this fail - CFile / SeekToEnd? Pin
charlieg10-Oct-12 6:43
membercharlieg10-Oct-12 6:43 
AnswerRe: Why does this fail - CFile / SeekToEnd? Pin
charlieg10-Oct-12 9:31
membercharlieg10-Oct-12 9:31 
AnswerRe: Why does this fail - CFile / SeekToEnd? Pin
Andrew Cherednik10-Oct-12 11:23
memberAndrew Cherednik10-Oct-12 11:23 
GeneralRe: Why does this fail - CFile / SeekToEnd? Pin
charlieg11-Oct-12 2:20
membercharlieg11-Oct-12 2:20 
AnswerRe: Why does this fail - CFile / SeekToEnd? Pin
Richard MacCutchan10-Oct-12 21:45
mvpRichard MacCutchan10-Oct-12 21:45 
GeneralRe: Why does this fail - CFile / SeekToEnd? Pin
charlieg11-Oct-12 2:30
membercharlieg11-Oct-12 2:30 
GeneralRe: Why does this fail - CFile / SeekToEnd? Pin
charlieg11-Oct-12 4:53
membercharlieg11-Oct-12 4:53 
GeneralRe: Why does this fail - CFile / SeekToEnd? Pin
Richard MacCutchan11-Oct-12 11:19
mvpRichard MacCutchan11-Oct-12 11:19 
GeneralRe: Why does this fail - CFile / SeekToEnd? Pin
charlieg11-Oct-12 11:34
membercharlieg11-Oct-12 11:34 
GeneralRe: Why does this fail - CFile / SeekToEnd? Pin
Richard MacCutchan11-Oct-12 12:01
mvpRichard MacCutchan11-Oct-12 12:01 

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

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


Advertise | Privacy | Mobile
Web03 | 2.8.150819.1 | Last Updated 29 Aug 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid