Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Something like:
Private m_blnHasFocusCashRB If m_blnHasFocusCashRB Then Application.Goto Reference "AccountNumber" m_blnHasFocusCashRB = False Else If ActiveCell = Range("AccountNumber") then Application.Goto Reference "Amount" else if ActiveCell = Range("Amount") then Sheet1.CashRB.Activate m_blnHasFocusCashRB = True End if End if "billQ" wrote in message ... Hi and thanks for the reply. I have a combination of cells, command buttons, and radio buttons that I am trying to set up a tab order using Application.OnKey("{TAB}", "tabPress" to capture the tab key. For tabPress I am using if then, elseif structure to determine the active cell or button and where to move the focus. ex) if ActiveCell = Range("AccountNumber") then Application.Goto Reference "Amount" else if ActiveCell = Range("Amount") then Sheet1.CashRB.Activate else if Sheet1.CashRB 'this is where I need to determine if the control has the focus so that I can move the focus to the next control how this give you more idea as to what I am trying to do. If I had to do it all over again I would make this sheet a form by itself. thanks bill "billq" wrote in message ... Hello, Need to know how to tell if a button has the focus. thanks bill |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Setting the focus | New Users to Excel | |||
focus | Excel Discussion (Misc queries) | |||
set focus | Excel Discussion (Misc queries) | |||
Focus | Excel Worksheet Functions | |||
set focus | Excel Programming |