title: GetDlgItemInt( ) problem
body: <p>Ok, i have 2 edit controls and a button in my main window; in one edit control the user can write a number and when he push the button i read that number and i print it in the other edit control (which is read only).</p>
  
  <p>My problem is that when i put a number and i press the button, for some reason that i dont understand i can get that number. And GetDlgItemInt() always return zero and his third parameter always return me false.</p>
  
  <p>This is the code where i use GetDlgItemInt () to read the number:</p>
  
  <pre><code>            case CM_BUTTON:
                  number = GetDlgItemInt(hwndEdit2, CM_EDIT2, &amp;flag, FALSE); 
                  if(flag)
                  {
                      if(number &gt; 0 &amp;&amp; number &lt; 20)
                      {
                          sprintf(message, "This is the number %d", number);
                          SetWindowText(hwndEdit, message);
                      }
                      else
                          MessageBox(hwnd, "Number to high or to low", "Error", MB_OK | MB_ICONWARNING);
                  }
                  else 
                      MessageBox(hwnd, "Error getting the number", "Error", MB_ICONEXCLAMATION | MB_OK);
                  break;
  </code></pre>
  
  <p>Any suggest?</p>