Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Question for Answers2000 again

Posted on 1998-12-10
1
Medium Priority
?
184 Views
Last Modified: 2013-11-20
Dear Answers2000,

Sorry for replying you late!!!

For the previous question, my problem is:

Before resizing the window, for example the size of the window is 400x400....
after resizing the window, the size of the window becomes 450x350.....

My question is how to get these two data in my program....and I want to use these two data at the same time..Can I do like this? Do you understand?

Thanks!!!
kkuu
0
Comment
Question by:kkuu
1 Comment
 
LVL 8

Accepted Solution

by:
Answers2000 earned 100 total points
ID: 1326011
OK first off the CString problem.

When you create a member variable you get a choice of what type

When you go to the member variables dialog, and double clickon your edit's id, say IDC_EDIT, a little dialog pops up.  You can set either a string or window type variable.  Your problem is you picked a CString, and you should have picked a CEdit.

To fix that problem
1. Ctrl-W bring up class wiz for your dialog
2. Go to member variables
3. You should see something like, in the list box
IDC_EDIT........CString.....m_edit
4. Highlight this line
5. Click Delete Variable
6. Now make sure that line is highlighted again
7. Pick Add Variable
8. When the dialog popups up entitled "Add Member Variable", it should have fields for Member Variable Name (an edit control), Category (a combo box) and Variable Type (a combo box)

In Member Variable name, type "m_edit"  - without the quotes
In Category pick "Control"
In Variable Type pick "CEdit"

This fixes the 2 compile errors you're getting


Your code should now compile, if you look at the previous comments in
http://www.experts-exchange.com/topics/comp/os-ms-windows/programming/mfc/Q.10105791
this explains the sizing code.

Remember the window can only one size at a time.  The reason the fix didn't work before, is it wouldn't compile, but if you re-read, I think it should make sense.

If not ask another follow up question.  

By the way, you don't need to keep opening new questions, I'll keep an eye on your progress.

0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…

972 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question