Click here to Skip to main content
15,893,161 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: focus in edit control Pin
bhogavalli suresh9-Sep-07 20:29
bhogavalli suresh9-Sep-07 20:29 
GeneralRe: focus in edit control Pin
Nishad S9-Sep-07 20:32
Nishad S9-Sep-07 20:32 
GeneralRe: focus in edit control Pin
Wamuti9-Sep-07 21:35
Wamuti9-Sep-07 21:35 
GeneralRe: focus in edit control Pin
Nishad S9-Sep-07 22:24
Nishad S9-Sep-07 22:24 
AnswerRe: focus in edit control Pin
Sreedhar DV9-Sep-07 20:33
Sreedhar DV9-Sep-07 20:33 
AnswerRe: focus in edit control Pin
Wamuti9-Sep-07 21:25
Wamuti9-Sep-07 21:25 
GeneralRe: focus in edit control Pin
Stephen Hewitt9-Sep-07 22:03
Stephen Hewitt9-Sep-07 22:03 
QuestionRe: focus in edit control Pin
Wamuti9-Sep-07 22:47
Wamuti9-Sep-07 22:47 
First, Thanks for the correction.
Second, sorry this is long but here goes;
When i tested SetFocus(), i placed it in two buttons as:

void CSetfocusDlg::OnBfirst() //first button
{
// TODO: Add your control notification handler code here
m_deOne.SetFocus();


}

void CSetfocusDlg::OnBsecond() //second button
{
// TODO: Add your control notification handler code here
m_deTwo.SetFocus();

}
and it worked just fine.

But if i am getting it right, if there is a button in a dialog, SetFocus() is reserved for the default push button, right?

This means that even if i put m_editControl.SetFocus() in OnInitDialog(), i would still not get the desired effect of setting the cursor to the Edit control(what i understand from the site you directed me and practically i have tried, so i was very wrong indeed).

Ofcourse it makes sense to use the WM_NEXTDLGCTL but i cant get the message in the class wizard. Then how do i code the handler? Please help!Sigh | :sigh:

Wamuti: Any man can be an island, but islands to need water around them!
Edmund Burke: No one could make a greater mistake than he who did nothing because he could do only a little.

GeneralRe: focus in edit control Pin
Wamuti9-Sep-07 22:54
Wamuti9-Sep-07 22:54 
QuestionDeviceIoControl Pin
Waldermort9-Sep-07 19:26
Waldermort9-Sep-07 19:26 
AnswerRe: DeviceIoControl Pin
Nishad S9-Sep-07 20:11
Nishad S9-Sep-07 20:11 
GeneralRe: DeviceIoControl Pin
Waldermort9-Sep-07 20:14
Waldermort9-Sep-07 20:14 
GeneralRe: DeviceIoControl Pin
Nishad S9-Sep-07 20:30
Nishad S9-Sep-07 20:30 
GeneralRe: DeviceIoControl Pin
Waldermort9-Sep-07 20:34
Waldermort9-Sep-07 20:34 
QuestionSOLVED Missing browse info in VC 6.0 [modified] Pin
Vaclav_9-Sep-07 17:06
Vaclav_9-Sep-07 17:06 
AnswerRe: Missing browse info in VC 6.0 Pin
ThatsAlok9-Sep-07 18:46
ThatsAlok9-Sep-07 18:46 
GeneralRe: Missing browse info in VC 6.0 Pin
Vaclav_9-Sep-07 20:32
Vaclav_9-Sep-07 20:32 
GeneralRe: Missing browse info in VC 6.0 Pin
ThatsAlok10-Sep-07 2:17
ThatsAlok10-Sep-07 2:17 
QuestionStart Topic Pin
monsieur_jj9-Sep-07 15:02
monsieur_jj9-Sep-07 15:02 
QuestionLINK : fatal error LNK1561: entry point must be defined?? [modified] Pin
ashokbngr9-Sep-07 14:48
ashokbngr9-Sep-07 14:48 
AnswerRe: LINK : fatal error LNK1561: entry point must be defined?? Pin
Mark Salsbery9-Sep-07 16:09
Mark Salsbery9-Sep-07 16:09 
QuestionStrange exception error while debugging Pin
minike9-Sep-07 14:05
minike9-Sep-07 14:05 
AnswerRe: Strange exception error while debugging Pin
Mark Salsbery9-Sep-07 14:16
Mark Salsbery9-Sep-07 14:16 
GeneralRe: Strange exception error while debugging Pin
minike9-Sep-07 14:41
minike9-Sep-07 14:41 
AnswerRe: Strange exception error while debugging Pin
Stephen Hewitt9-Sep-07 17:20
Stephen Hewitt9-Sep-07 17:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.