Click here to Skip to main content
15,923,120 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: dbf file Pin
David Crow23-Apr-04 9:41
David Crow23-Apr-04 9:41 
GeneralHTTP POST Pin
aman200623-Apr-04 8:05
aman200623-Apr-04 8:05 
GeneralRe: HTTP POST Pin
Mike Dimmick23-Apr-04 9:16
Mike Dimmick23-Apr-04 9:16 
GeneralRe: HTTP POST Pin
aman200623-Apr-04 10:03
aman200623-Apr-04 10:03 
GeneralRe: HTTP POST Pin
Jeff Bogan23-Apr-04 10:39
Jeff Bogan23-Apr-04 10:39 
GeneralUnable to capture lostFocus event of CRichEditCtrl Pin
Chauhan Chirag23-Apr-04 6:56
Chauhan Chirag23-Apr-04 6:56 
GeneralRe: Unable to capture lostFocus event of CRichEditCtrl Pin
David Crow23-Apr-04 7:16
David Crow23-Apr-04 7:16 
GeneralRe: Unable to capture lostFocus event of CRichEditCtrl Pin
Chauhan Chirag23-Apr-04 7:38
Chauhan Chirag23-Apr-04 7:38 
Thanks for replying
No, OnKillFocus() is not working.
Actually wat i have done is create a subclass of CRichEditCtrl and that i have included in the Dialog that facilitates me to capture KeyPress event.
The code snippet is sumthing like this:

BOOL CSend::PreTranslateMessage(MSG* pMsg)
{
extern char userStatus[50];

if (pMsg->message == WM_KEYDOWN)
strcpy(this->userStatus,"Typing");
return CRichEditCtrl::PreTranslateMessage(pMsg);
}

but , then i have find out that Lost Focus is Mouse event and that cannot be handled using abouve snippet so i have tried a different this which is as follows:
BOOL CChat::OnNotify(WPARAM wParam, LPARAM lParam, LRESULT* pResult)
{
// TODO: Add your specialized code here and/or call the base class
NMHDR* pNMHDR = (NMHDR *)lParam;

if(pNMHDR && pNMHDR->code == NM_KILLFOCUS)
{
CWnd *pFocus = CWnd::GetFocus(); // call to a static function
if(pFocus &&(pFocus->GetParent() == this))
{
if(pFocus->GetDlgCtrlID() == TXT_SEND)
MessageBox("here",NULL,MB_OK);
}
}

return CDialog::OnNotify(wParam, lParam, pResult);
}

OR

BOOL CChat::OnCommand(WPARAM wParam, LPARAM lParam)
{
// TODO: Add your specialized code here and/or call the base class
UINT notificationCode = (UINT) HIWORD(wParam);

return CDialog::OnCommand(wParam, lParam);
}

But stll unable 2 capture lost focus event of CRichEditCtrl.
GeneralRe: Unable to capture lostFocus event of CRichEditCtrl Pin
David Crow23-Apr-04 7:41
David Crow23-Apr-04 7:41 
GeneralRe: Unable to capture lostFocus event of CRichEditCtrl Pin
Chauhan Chirag23-Apr-04 8:25
Chauhan Chirag23-Apr-04 8:25 
GeneralMFC - Flexgrid issue Pin
sanjay zore23-Apr-04 5:52
sanjay zore23-Apr-04 5:52 
GeneralRe: MFC - Flexgrid issue Pin
Mike Dimmick23-Apr-04 9:17
Mike Dimmick23-Apr-04 9:17 
QuestionHow to change the font size of an Edit control? Pin
Cyrus Dang23-Apr-04 4:59
Cyrus Dang23-Apr-04 4:59 
AnswerRe: How to change the font size of an Edit control? Pin
David Crow23-Apr-04 5:29
David Crow23-Apr-04 5:29 
GeneralRe: How to change the font size of an Edit control? Pin
Cyrus Dang23-Apr-04 5:33
Cyrus Dang23-Apr-04 5:33 
GeneralRe: How to change the font size of an Edit control? Pin
Navin23-Apr-04 5:36
Navin23-Apr-04 5:36 
GeneralRe: How to change the font size of an Edit control? Pin
David Crow23-Apr-04 6:04
David Crow23-Apr-04 6:04 
GeneralRe: How to change the font size of an Edit control? Pin
Cyrus Dang23-Apr-04 6:06
Cyrus Dang23-Apr-04 6:06 
GeneralSwitch btwn nested and non-nested Splitters Pin
mike-o23-Apr-04 4:56
mike-o23-Apr-04 4:56 
GeneralRe: Switch btwn nested and non-nested Splitters Pin
Gary R. Wheeler23-Apr-04 11:30
Gary R. Wheeler23-Apr-04 11:30 
QuestionHow to convert CBitmap to DIB and backwards Pin
uus9923-Apr-04 4:51
uus9923-Apr-04 4:51 
AnswerRe: How to convert CBitmap to DIB and backwards Pin
Chris Losinger23-Apr-04 7:28
professionalChris Losinger23-Apr-04 7:28 
AnswerRe: How to convert CBitmap to DIB and backwards Pin
John R. Shaw23-Apr-04 17:20
John R. Shaw23-Apr-04 17:20 
GeneralRe: How to convert CBitmap to DIB and backwards Pin
uus9923-Apr-04 21:14
uus9923-Apr-04 21:14 
GeneralRe: How to convert CBitmap to DIB and backwards Pin
John R. Shaw27-Apr-04 5:43
John R. Shaw27-Apr-04 5:43 

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.