I want to disable the mosue movement in a MFC view application if the control is in an edit box and user entering data in the edit box. I want to get back the mouse movement once user presses enter key in the edit box, can anybody tell me how can I do this in MFC view application
I have multiple modeless dialog with each dialog have some edit box controls on it. So when user entering data in to an edit box of modeless dialog and at the same time if user moves the mouse away from that modeless dialog the focus is changing from the edit box to parent window which is making wrong values to be set in the edit box. So I want to disable this mouse movement until the user done with data entry into the edit box. yeah it seems like counter-productive but the requirment is like that
While I'm not sure how good an idea it is, perhaps you want to look into mouse capture. See here and here. You could try to capture the mouse on first character entered into the control and release it on tab or enter. I'm still not confident that this won't be misunderstood by users and frustrate them.
Edit: Richard's response is better. Listen to him.
You might want to rethink this. It is an unusual approach and will be misunderstood by users. Having the mouse cursor disappear or become unresponsive will be interpreted by many users as a program hang. Some will respond by bringing up task manager to kill your program. Others will reboot their computer to get things working again. Neither is a good thing. (Yesterday I was trying to help a user who is using some buggy, no longer supported legacy software. He would have done ;exactly this ;with no hesitation.)
Perhaps you could validate the data at some point and notify the user if it is invalid. You could even set focus back to the offending control.
SetCurrentDirectory works in MFC.
Check if your path is valid.
Also you could use GetLastError after the failure of the function.
If the path is OK then some relevant code snippet about your problem could also help us to find the problem.
Making desired black pixel as center of your search and then exploring the pixels around, if not found increasing in 1 your search radius and try again, when you have a hit in white, getting its coordinates and making the modul of the vector from point A to B to get the distance.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpfull answers is nice, but saying thanks can be even nicer.
i have dialog based application in which i add menu form menu resource now i want to set font name and background colour of menu items but it never get reflected.please anyone tell me how to change the font name and background colour of menu in dialog based application in vc++,mfc
I have an application that is loading a iso file. iso file has many packages to complete the application but it takes time to open an application because everytime it load all packages. So I want to take snapshot like thing So that i can resume the application from where I left it before.