It's good programming practice to do it this way, as from the client code you can always refer to the CMyDlg::IDD without worrying what the actual constant is.