Click here to Skip to main content
15,891,529 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Problem with reading a file Pin
kakan4-Sep-09 3:08
professionalkakan4-Sep-09 3:08 
QuestionUpdating UI from thread Pin
_80863-Sep-09 16:54
_80863-Sep-09 16:54 
AnswerRe: Updating UI from thread Pin
«_Superman_»3-Sep-09 17:20
professional«_Superman_»3-Sep-09 17:20 
GeneralRe: Updating UI from thread Pin
_80863-Sep-09 17:39
_80863-Sep-09 17:39 
GeneralRe: Updating UI from thread Pin
«_Superman_»3-Sep-09 17:45
professional«_Superman_»3-Sep-09 17:45 
AnswerRe: Updating UI from thread Pin
Cedric Moonen3-Sep-09 20:03
Cedric Moonen3-Sep-09 20:03 
AnswerRe: Updating UI from thread Pin
Rajesh R Subramanian3-Sep-09 20:16
professionalRajesh R Subramanian3-Sep-09 20:16 
Questionbutton(visible&Enable) but CANNOT be pressed Pin
fitatc3-Sep-09 14:48
fitatc3-Sep-09 14:48 
Confused | :confused: My qustion is Why this happened???
if sibling window paint by Z-order according to MSDN doc, the button should not be painted after the dialog.
http://msdn.microsoft.com/en-us/library/dd183426(VS.85).aspx[^]
--------------------------------------------------------------
Do the follow simple step you will see the "magic" button:
1. Create MFC SDI project
2. At [resouce view], Add a dialog and set style child.(WS_CHILD)
3. Add this code to the *view.cpp to create to child window:
 #define BTN1 10101
 int CTestView::OnCreate(LPCREATESTRUCT lpCreateStruct)
 {
  if (CView::OnCreate(lpCreateStruct) == -1)
   return -1;

  // TODO:  ここに特定な作成コードを追加してください。
   m_dlg.Create(CTestDlg::IDD, this);
  m_dlg.ShowWindow(SW_SHOW);
  RECT rect;
  rect.left = 10;
  rect.top = 100;
  rect.right = 110;
  rect.bottom = 125;
  m_btn.Create(_T("testBtn"), WS_VISIBLE | BS_PUSHBUTTON, rect, this, BTN1);
  return 0;
 }

* CTestDlg m_dlg, CButton m_btn is member of the CTestView
* Z-order can be checked either by Spy++ or GetWindow API

You can fix the problem by add WS_CLIPSIBLINGS style of the button.
m_btn.Create(_T("testBtn"), WS_VISIBLE | BS_PUSHBUTTON | WS_CLIPSIBLINGS, rect, this, BTN1);

AnswerRe: button(visible&Enable) but CANNOT be pressed Pin
Eric Haddan4-Sep-09 4:48
Eric Haddan4-Sep-09 4:48 
GeneralRe: button(visible&Enable) but CANNOT be pressed Pin
fitatc6-Sep-09 18:20
fitatc6-Sep-09 18:20 
Questionvector question Pin
RobJones3-Sep-09 11:50
RobJones3-Sep-09 11:50 
AnswerRe: vector question Pin
Nemanja Trifunovic3-Sep-09 12:08
Nemanja Trifunovic3-Sep-09 12:08 
GeneralRe: vector question Pin
RobJones3-Sep-09 12:12
RobJones3-Sep-09 12:12 
QuestionTemplates... they are nasty!! Pin
o.kauert3-Sep-09 11:43
o.kauert3-Sep-09 11:43 
AnswerRe: Templates... they are nasty!! Pin
Nemanja Trifunovic3-Sep-09 12:20
Nemanja Trifunovic3-Sep-09 12:20 
AnswerRe: Templates... they are nasty!! [modified] Pin
Chris Losinger3-Sep-09 16:15
professionalChris Losinger3-Sep-09 16:15 
GeneralRe: Templates... they are nasty!! Pin
«_Superman_»3-Sep-09 17:41
professional«_Superman_»3-Sep-09 17:41 
GeneralRe: Templates... they are nasty!! Pin
o.kauert3-Sep-09 23:14
o.kauert3-Sep-09 23:14 
AnswerRe: Templates... they are nasty!! Pin
Stuart Dootson3-Sep-09 21:44
professionalStuart Dootson3-Sep-09 21:44 
GeneralRe: Templates... they are nasty!! Pin
o.kauert3-Sep-09 23:27
o.kauert3-Sep-09 23:27 
GeneralRe: Templates... they are nasty!! Pin
Stuart Dootson3-Sep-09 23:37
professionalStuart Dootson3-Sep-09 23:37 
GeneralRe: Templates... they are nasty!! Pin
o.kauert4-Sep-09 0:54
o.kauert4-Sep-09 0:54 
GeneralRe: Templates... they are nasty!! Pin
Stuart Dootson4-Sep-09 1:00
professionalStuart Dootson4-Sep-09 1:00 
GeneralRe: Templates... they are nasty!! Pin
o.kauert4-Sep-09 1:40
o.kauert4-Sep-09 1:40 
GeneralRe: Templates... they are nasty!! Pin
Stuart Dootson4-Sep-09 1:52
professionalStuart Dootson4-Sep-09 1:52 

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.