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

C / C++ / MFC

 
AnswerRe: MD5 - different results Pin
Stuart Dootson11-Dec-08 2:32
professionalStuart Dootson11-Dec-08 2:32 
GeneralRe: MD5 - different results Pin
gabbana11-Dec-08 2:42
gabbana11-Dec-08 2:42 
QuestionHow to allow the user to enter a value between 0x00 and 0xFF in an edit box ? Pin
kapardhi11-Dec-08 1:47
kapardhi11-Dec-08 1:47 
AnswerRe: How to allow the user to enter a value between 0x00 and 0xFF in an edit box ? Pin
Stuart Dootson11-Dec-08 2:34
professionalStuart Dootson11-Dec-08 2:34 
AnswerRe: How to allow the user to enter a value between 0x00 and 0xFF in an edit box ? Pin
David Crow11-Dec-08 8:15
David Crow11-Dec-08 8:15 
QuestionHow can add button in ListCtlr? Pin
Le@rner11-Dec-08 0:01
Le@rner11-Dec-08 0:01 
AnswerRe: How can add button in ListCtlr? Pin
_AnsHUMAN_ 11-Dec-08 0:25
_AnsHUMAN_ 11-Dec-08 0:25 
QuestionTooltips on CView Pin
Redeye9210-Dec-08 23:50
Redeye9210-Dec-08 23:50 
What I'm trying to do is add tooltips to a CView derived window so that I can change the text in the tooltip (or not display it at all) depending on where the cursor is and the state of various other things going on in the application (it's mostly just going to be for showing error states for things on the network). I'm not using any Windows controls at all on the view - the view basically just draws a bitmap.

What I've done is create the tooltip in PreCreateWindow as follows :

theApp.GetTooltipManager()->CreateToolTip(m_pToolTip, this, AFX_TOOLTIP_TYPE_DEFAULT);
m_pToolTip->AddTool(this, LPSTR_TEXTCALLBACK, CRect(0,0,600,600), 1);
EnableToolTips(TRUE);
m_pToolTip->Activate(TRUE);


I've added a handler in both the view and mainframe classes for the TTN_NEEDTEXT message (I'm not entirely sure which one it's supposed to go to in this scenario). I've also added m_pToolTip->RelayEvent(pMsg) into PreTranslateMessage.

But the TTN_NEEDTEXT message handlers never get called and no tooltip ever gets shown even if I hard code the tooltip text instead of using LPSTR_TEXTCALLBACK.

Can anybody shed any light on this for me? I've no doubt that this is a schoolboy error and I'll feel a complete fool when someone points out my stupidity, but I think I'm ready to accept that now...

Thanks in advance.
AnswerRe: Tooltips on CView Pin
Iain Clarke, Warrior Programmer11-Dec-08 0:22
Iain Clarke, Warrior Programmer11-Dec-08 0:22 
GeneralRe: Tooltips on CView Pin
Redeye9212-Dec-08 4:46
Redeye9212-Dec-08 4:46 
Questionhow to create registry and how to write data to registry? Pin
puppya10-Dec-08 23:03
puppya10-Dec-08 23:03 
AnswerRe: how to create registry and how to write data to registry? Pin
enhzflep10-Dec-08 23:17
enhzflep10-Dec-08 23:17 
GeneralRe: how to create registry and how to write data to registry? Pin
puppya10-Dec-08 23:25
puppya10-Dec-08 23:25 
AnswerRe: how to create registry and how to write data to registry? Pin
VC++Maniac10-Dec-08 23:38
VC++Maniac10-Dec-08 23:38 
GeneralRe: how to create registry and how to write data to registry? Pin
_AnsHUMAN_ 10-Dec-08 23:39
_AnsHUMAN_ 10-Dec-08 23:39 
GeneralRe: how to create registry and how to write data to registry? Pin
Sarath C10-Dec-08 23:45
Sarath C10-Dec-08 23:45 
AnswerRe: how to create registry and how to write data to registry? Pin
Hamid_RT11-Dec-08 2:49
Hamid_RT11-Dec-08 2:49 
QuestionHow to send CFrameWndEx pointer to COleClientItem::OnGetWindowContext Pin
sativijji10-Dec-08 22:41
sativijji10-Dec-08 22:41 
QuestionDestroyInPlaceFrame to destroy CFrameWndEx Pin
sativijji10-Dec-08 22:37
sativijji10-Dec-08 22:37 
Questionhow to show IPaddress control on status bar(in 4th pane) on a dialog based application? Pin
puppya10-Dec-08 22:34
puppya10-Dec-08 22:34 
AnswerRe: how to show IPaddress control on status bar(in 4th pane) on a dialog based application? Pin
Sarath C10-Dec-08 22:46
Sarath C10-Dec-08 22:46 
GeneralRe: how to show IPaddress control on status bar(in 4th pane) on a dialog based application? Pin
puppya10-Dec-08 22:55
puppya10-Dec-08 22:55 
GeneralRe: how to show IPaddress control on status bar(in 4th pane) on a dialog based application? Pin
_AnsHUMAN_ 10-Dec-08 23:44
_AnsHUMAN_ 10-Dec-08 23:44 
AnswerRe: how to show IPaddress control on status bar(in 4th pane) on a dialog based application? Pin
Iain Clarke, Warrior Programmer10-Dec-08 23:56
Iain Clarke, Warrior Programmer10-Dec-08 23:56 
QuestionDrawing on a Static control [modified] Pin
koumodaki10-Dec-08 22:00
koumodaki10-Dec-08 22:00 

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.