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

C / C++ / MFC

 
GeneralRe: messin with javascript Pin
Dr.Walt Fair, PE5-Jun-10 17:54
professionalDr.Walt Fair, PE5-Jun-10 17:54 
AnswerRe: messin with javascript Pin
David Crow7-Jun-10 4:25
David Crow7-Jun-10 4:25 
QuestionLoadLibrary() loads a driver ?! Pin
Green Fuze4-Jun-10 14:17
Green Fuze4-Jun-10 14:17 
AnswerRe: LoadLibrary() loads a driver ?! Pin
Randor 4-Jun-10 17:15
professional Randor 4-Jun-10 17:15 
GeneralRe: LoadLibrary() loads a driver ?! Pin
Green Fuze4-Jun-10 20:31
Green Fuze4-Jun-10 20:31 
Questionvector class memory usage [modified] Pin
James_7224-Jun-10 7:06
James_7224-Jun-10 7:06 
AnswerRe: vector class memory usage Pin
Cedric Moonen4-Jun-10 7:45
Cedric Moonen4-Jun-10 7:45 
QuestionRe: vector class memory usage Pin
Maximilien4-Jun-10 8:32
Maximilien4-Jun-10 8:32 
AnswerRe: vector class memory usage Pin
Aescleal4-Jun-10 10:34
Aescleal4-Jun-10 10:34 
QuestionWrite Specific File Properties [Solved] Pin
jlangholzj4-Jun-10 5:46
jlangholzj4-Jun-10 5:46 
AnswerRe: Write Specific File Properties Pin
Nuri Ismail4-Jun-10 5:57
Nuri Ismail4-Jun-10 5:57 
GeneralRe: Write Specific File Properties Pin
jlangholzj4-Jun-10 6:09
jlangholzj4-Jun-10 6:09 
QuestionReadOnly Radio button Pin
Anu_Bala3-Jun-10 20:35
Anu_Bala3-Jun-10 20:35 
AnswerRe: ReadOnly Radio button Pin
Niklas L3-Jun-10 22:02
Niklas L3-Jun-10 22:02 
GeneralRe: ReadOnly Radio button Pin
Code-o-mat3-Jun-10 22:22
Code-o-mat3-Jun-10 22:22 
AnswerRe: ReadOnly Radio button Pin
Code-o-mat3-Jun-10 22:12
Code-o-mat3-Jun-10 22:12 
GeneralRe: ReadOnly Radio button Pin
Niklas L3-Jun-10 22:21
Niklas L3-Jun-10 22:21 
GeneralRe: ReadOnly Radio button Pin
Code-o-mat3-Jun-10 22:23
Code-o-mat3-Jun-10 22:23 
GeneralRe: ReadOnly Radio button Pin
Niklas L3-Jun-10 22:35
Niklas L3-Jun-10 22:35 
GeneralRe: ReadOnly Radio button Pin
Anu_Bala3-Jun-10 22:38
Anu_Bala3-Jun-10 22:38 
GeneralRe: ReadOnly Radio button Pin
Code-o-mat3-Jun-10 22:47
Code-o-mat3-Jun-10 22:47 
GeneralRe: ReadOnly Radio button Pin
Anu_Bala3-Jun-10 23:51
Anu_Bala3-Jun-10 23:51 
GeneralRe: ReadOnly Radio button Pin
Code-o-mat4-Jun-10 0:08
Code-o-mat4-Jun-10 0:08 
Derive a class from CButton, handle those messages in this derived class and use it for your radio.
Something like this:
CReadOnlyRadio: public CButton
{
public:
  DECLARE_MESSAGE_MAP()
  void OnLButtonDown(UINT nFlags, CPoint point) { /*Nothing here on purpose*/ }
  void OnLButtonUp(UINT nFlags, CPoint point) { /*Nothing here on purpose*/ }
  void OnLButtonDblClk(UINT nFlags, CPoint point) { /*Nothing here on purpose*/ }
  void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags) { /*Nothing here on purpose*/ }
  void OnKeyUp(UINT nChar, UINT nRepCnt, UINT nFlags) { /*Nothing here on purpose*/ }
  void OnChar(UINT nChar, UINT nRepCnt, UINT nFlags) { /*Nothing here on purpose*/ }
};
...
BEGIN_MESSAGE_MAP(CReadOnlyRadio, CButton)
  ON_WM_LBUTTONDOWN()
  ON_WM_LBUTTONUP()
  ON_WM_LBUTTONDBLCLK()
  ON_WM_KEYDOWN()
  ON_WM_KEYUP()
  ON_WM_CHAR()
END_MESSAGE_MAP()
...
class CMyFancyDialog: public CDialog
{
 ...
 DoDataExchange(CDataExchange* pDX);
 CReadOnlyRadio  m_ReadOnlyRadio;
 ...
};
...
void CMyFancyDialog::DoDataExchange(CDataExchange* pDX)
{
  CDialog::DoDataExchange(pDX);
  ...
  DDX_Control(pDX, IDC_READONLY_RADIO, m_ReadOnlyRadio);
  ...
}
...

Hope it is understandable...
> The problem with computers is that they do what you tell them to do and not what you want them to do. <
> Computers are evil, EVIL i tell you!! <

GeneralRe: ReadOnly Radio button Pin
Rick York4-Jun-10 8:11
mveRick York4-Jun-10 8:11 
GeneralRe: ReadOnly Radio button Pin
Code-o-mat4-Jun-10 9:12
Code-o-mat4-Jun-10 9:12 

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.