Click here to Skip to main content
15,902,189 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionChar* not maintaing correct assigned Values Pin
jcp121729-Nov-10 17:36
jcp121729-Nov-10 17:36 
AnswerRe: Char* not maintaing correct assigned Values Pin
Luc Pattyn29-Nov-10 17:45
sitebuilderLuc Pattyn29-Nov-10 17:45 
QuestionHow to read .txt file and find delimiter ? Pin
mathivanaan29-Nov-10 17:22
mathivanaan29-Nov-10 17:22 
AnswerRe: How to read .txt file and find delimiter ? Pin
Luc Pattyn29-Nov-10 17:49
sitebuilderLuc Pattyn29-Nov-10 17:49 
AnswerRe: How to read .txt file and find delimiter ? Pin
Adam Roderick J29-Nov-10 18:00
Adam Roderick J29-Nov-10 18:00 
QuestionRe: How to read .txt file and find delimiter ? Pin
David Crow30-Nov-10 5:11
David Crow30-Nov-10 5:11 
QuestionUser Button Notification Codes: BN_CLICKED, is there a way to get notification when it is unclicked? Pin
Paul Belikian29-Nov-10 17:02
Paul Belikian29-Nov-10 17:02 
AnswerRe: User Button Notification Codes: BN_CLICKED, is there a way to get notification when it is unclicked? Pin
Luc Pattyn29-Nov-10 17:50
sitebuilderLuc Pattyn29-Nov-10 17:50 
GeneralRe: User Button Notification Codes: BN_CLICKED, is there a way to get notification when it is unclicked? Pin
Paul Belikian29-Nov-10 18:21
Paul Belikian29-Nov-10 18:21 
AnswerRe: User Button Notification Codes: BN_CLICKED, is there a way to get notification when it is unclicked? Pin
David Crow30-Nov-10 5:14
David Crow30-Nov-10 5:14 
GeneralRe: User Button Notification Codes: BN_CLICKED, is there a way to get notification when it is unclicked? Pin
Paul Belikian30-Nov-10 10:19
Paul Belikian30-Nov-10 10:19 
GeneralRe: User Button Notification Codes: BN_CLICKED, is there a way to get notification when it is unclicked? Pin
Roger Allen1-Dec-10 5:44
Roger Allen1-Dec-10 5:44 
GeneralRe: User Button Notification Codes: BN_CLICKED, is there a way to get notification when it is unclicked? Pin
Paul Belikian1-Dec-10 7:10
Paul Belikian1-Dec-10 7:10 
QuestionSave as HTML to text file Pin
Max++29-Nov-10 16:36
Max++29-Nov-10 16:36 
AnswerRe: Save as HTML to text file Pin
visualheadsky29-Nov-10 17:14
visualheadsky29-Nov-10 17:14 
QuestionSpin control , it's possible to know when the control is released? Pin
timbk29-Nov-10 16:05
timbk29-Nov-10 16:05 
AnswerRe: Spin control , it's possible to know when the control is released? Pin
Code-o-mat30-Nov-10 1:56
Code-o-mat30-Nov-10 1:56 
GeneralRe: Spin control , it's possible to know when the control is released? Pin
timbk30-Nov-10 8:33
timbk30-Nov-10 8:33 
GeneralRe: Spin control , it's possible to know when the control is released? Pin
Code-o-mat30-Nov-10 8:43
Code-o-mat30-Nov-10 8:43 
GeneralRe: Spin control , it's possible to know when the control is released? Pin
timbk30-Nov-10 9:29
timbk30-Nov-10 9:29 
GeneralRe: Spin control , it's possible to know when the control is released? Pin
Code-o-mat30-Nov-10 10:10
Code-o-mat30-Nov-10 10:10 
GeneralRe: Spin control , it's possible to know when the control is released? Pin
timbk30-Nov-10 10:18
timbk30-Nov-10 10:18 
GeneralRe: Spin control , it's possible to know when the control is released? Pin
Code-o-mat30-Nov-10 10:33
Code-o-mat30-Nov-10 10:33 
This might be re-inventing the wheel but try this:
class CMySpin: public CSpinButtonCtrl
{
protected:
  DECLARE_MESSAGE_MAP()
  afx_msg void OnCaptureChanged(CWnd *pWnd);
};


and the implementation:
BEGIN_MESSAGE_MAP(CMySpin, CSpinButtonCtrl)
  ON_WM_CAPTURECHANGED()
END_MESSAGE_MAP()

void CMySpin::OnCaptureChanged(CWnd *pWnd)
{
  CSpinButtonCtrl::OnCaptureChanged(pWnd);
  if (pWnd != this) 
  {
    NMHDR NMHdr;
    NMHdr.code      = NM_RELEASEDCAPTURE;
    NMHdr.hwndFrom  = m_hWnd;
    NMHdr.idFrom    = GetDlgCtrlID();
    GetParent()->SendMessage(WM_NOTIFY, NMHdr.idFrom, (LPARAM)&NMHdr);
  }
}

use a CMySpin as a control variable for your spin button in your dialog. (You might need to modify the code to compile under VS6, don't know what has changed since VS6)
> The problem with computers is that they do what you tell them to do and not what you want them to do. <
> Leela: Fry, you're wasting your life sitting in front of that TV. You need to get out and see the real world.
Fry: But this is HDTV. It's got better resolution than the real world <
>Nothing is free in the universe.<

GeneralRe: Spin control , it's possible to know when the control is released? Pin
timbk30-Nov-10 12:04
timbk30-Nov-10 12:04 
AnswerSolved: Spin control , it's possible to know when the control is released? Pin
timbk30-Nov-10 15:16
timbk30-Nov-10 15:16 

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.