Jump to content

Tabbing out of edit box


Recommended Posts

Guest dynamowku
Posted

I have a dialog that has two list boxes and an edit box.

<List>

<List>

<Edit>

Once I arrow into the edit box the cursor is "stuck" there and I cannot get the focus to go back to a list box! Can someone please help me with this?

Thanks!

  • 4 months later...
Guest Ravi Ranjan
Posted
I have a dialog that has two list boxes and an edit box.

Once I arrow into the edit box the cursor is "stuck" there and I cannot get the focus to go back to a list box! Can someone please help me with this?

Thanks!

<{POST_SNAPBACK}>

Hi,

Try using window subclassing.for example

LRESULT APIENTRY EditSubclassProc(HWND hwnd,UINT uMsg,WPARAM wParam,LPARAM lParam) 

{ 

	switch(wParam)

	{

  case VK_DOWN :  // your code to change the focus on which u want

 	 break;

  case VK_UP :  // your code to change the focus on which u want


    break;

  


	}


    return CallWindowProc(m_OldProcEdit,hwnd, uMsg,wParam, lParam); 

}
and in initdialog() call
m_OldProcEdit= (WNDPROC) SetWindowLong(hwndEdit,GWL_WNDPROC,(long) (WNDPROC)EditSubclassProcc);

Ravi Ranjan

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.