Solved

What is the active control?

Posted on 1999-01-18
4
149 Views
Last Modified: 2011-10-03
I need to know what is the active control? Is there some way to know this?
 Jose Hernandez




0
Comment
Question by:al361345
  • 2
4 Comments
 

Author Comment

by:al361345
ID: 1469246
Edited text of question
0
 
LVL 69

Accepted Solution

by:
Éric Moreau earned 50 total points
ID: 1469247
Look at Screen.ActiveControl.
0
 
LVL 3

Expert Comment

by:traygreen
ID: 1469248
If you need to find the control at runtime...
Select case ActiveControl.Name
  case "text1"
    call text1_gotfocus(ActiveControl.Index)
    ' or whatever you want to happen
end select
0
 

Author Comment

by:al361345
ID: 1469249
Thanks you emoreau and traygreen.
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now