Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
I want it so that if someone selects an option button, the tab key will fire and automatically select the next option based on tab order. BTW, the next option is a text box. Private Sub Sub_Catch_Value_Click() If Sub_Catch_Value = True Then RainValue.Value = 0 Application.SendKeys ("TAB") End If End Sub But this does not work. It inputs the data into the text box but does not then select it for input. There must be a better way? -- Regards, Glen Millar Microsoft PPT MVP http://www.powerpointworkbench.com/ Please tell us your ppt version, and get back to us here Remove spaces from signature Posted to news://msnews.microsoft.com |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
Cracked it.: Application.SendKeys "{TAB}" The one I had just sends text. -- Regards, Glen Millar Microsoft PPT MVP http://www.powerpointworkbench.com/ Please tell us your ppt version, and get back to us here Remove spaces from signature Posted to news://msnews.microsoft.com "Glen Millar" <glen @ powerpointworkbench.com wrote in message ... Hi, I want it so that if someone selects an option button, the tab key will fire and automatically select the next option based on tab order. BTW, the next option is a text box. Private Sub Sub_Catch_Value_Click() If Sub_Catch_Value = True Then RainValue.Value = 0 Application.SendKeys ("TAB") End If End Sub But this does not work. It inputs the data into the text box but does not then select it for input. There must be a better way? -- Regards, Glen Millar Microsoft PPT MVP http://www.powerpointworkbench.com/ Please tell us your ppt version, and get back to us here Remove spaces from signature Posted to news://msnews.microsoft.com |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Glen,
You can ascertain the tab order and use the SetFocus method of the control you want to have the focus. Personally, I eschew SendKeys. Bob "Glen Millar" <glen @ powerpointworkbench.com wrote in message ... Hi, Cracked it.: Application.SendKeys "{TAB}" The one I had just sends text. -- Regards, Glen Millar Microsoft PPT MVP http://www.powerpointworkbench.com/ Please tell us your ppt version, and get back to us here Remove spaces from signature Posted to news://msnews.microsoft.com "Glen Millar" <glen @ powerpointworkbench.com wrote in message ... Hi, I want it so that if someone selects an option button, the tab key will fire and automatically select the next option based on tab order. BTW, the next option is a text box. Private Sub Sub_Catch_Value_Click() If Sub_Catch_Value = True Then RainValue.Value = 0 Application.SendKeys ("TAB") End If End Sub But this does not work. It inputs the data into the text box but does not then select it for input. There must be a better way? -- Regards, Glen Millar Microsoft PPT MVP http://www.powerpointworkbench.com/ Please tell us your ppt version, and get back to us here Remove spaces from signature Posted to news://msnews.microsoft.com |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks, Bob. I'll chase up the SetFocus.
-- Regards, Glen Millar Microsoft PPT MVP http://www.powerpointworkbench.com/ Please tell us your ppt version, and get back to us here Remove spaces from signature Posted to news://msnews.microsoft.com "Bob Kilmer" wrote in message ... Glen, You can ascertain the tab order and use the SetFocus method of the control you want to have the focus. Personally, I eschew SendKeys. Bob "Glen Millar" <glen @ powerpointworkbench.com wrote in message ... Hi, Cracked it.: Application.SendKeys "{TAB}" The one I had just sends text. -- Regards, Glen Millar Microsoft PPT MVP http://www.powerpointworkbench.com/ Please tell us your ppt version, and get back to us here Remove spaces from signature Posted to news://msnews.microsoft.com "Glen Millar" <glen @ powerpointworkbench.com wrote in message ... Hi, I want it so that if someone selects an option button, the tab key will fire and automatically select the next option based on tab order. BTW, the next option is a text box. Private Sub Sub_Catch_Value_Click() If Sub_Catch_Value = True Then RainValue.Value = 0 Application.SendKeys ("TAB") End If End Sub But this does not work. It inputs the data into the text box but does not then select it for input. There must be a better way? -- Regards, Glen Millar Microsoft PPT MVP http://www.powerpointworkbench.com/ Please tell us your ppt version, and get back to us here Remove spaces from signature Posted to news://msnews.microsoft.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Click Option Button 2x in a Row | Excel Discussion (Misc queries) | |||
Option Button code not working | Excel Discussion (Misc queries) | |||
right-click on a control button and view code does nothing | Excel Worksheet Functions | |||
keep source formatting is not an option in paste option button | Excel Discussion (Misc queries) | |||
Running command button click event code | Excel Programming |