|
-
February 19th, 2009, 08:05 AM
#26
Re: CEdit::Create & GetWindowRect
 Originally Posted by Mybowlcut
Code:
CEdit at_edit; // change to CDecimalEdit at_edit;
CEdit ra_edit; // change to CDecimalEdit ra_edit;
CEdit rh_edit; // change to CDecimalEdit rh_edit;
CEdit sr_edit; // change to CDecimalEdit sr_edit;
CEdit wd_edit; // change to CDecimalEdit wd_edit;
CEdit ws_edit; // change to CDecimalEdit ws_edit;
afx_msg void OnEnChangeEditAt();
afx_msg void OnEnChangeEditWd();
afx_msg void OnEnChangeEditRh();
afx_msg void OnEnChangeEditRa();
afx_msg void OnEnChangeEditWs();
afx_msg void OnEnChangeEditSr();
};
I always understood that that is what you meant. But my question was, if I wanted to place the controls visually, then how would I change the type? It has been confirmed that by placing the controls visually, it is easier to position them, they come with the client edge and normal font as default and it's generally a lot easier. But when I click on Edit control in the toolbox and make one, I do not see a way to change its type as there is no instance created in the dialog's code. The link to the post you gave me does not explain this. It tells me to use the add variable wizard, which is not what I wanted to do (see this post).
You don't change the type when adding the variable. As your comments indicate above, you let it create CEdit variables and change it yourself. I've said that at least four times now.
Change this
to this
Code:
CDecimalEdit ws_edit;
That's it. That's all. You're done.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|