473,385 Members | 1,846 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Finding which control triggers the Lost focus

I have a situation wherein i have a text box, that has abc()[a validation
method that leaves the focus on the same control if not validated] being
executed whenever the lost focus event is triggered. However, there is an
exceptional case where, if a button click causes the lost focus, I do not
want abc() to be called. Is there a method by which one can find out which
control is triggering the lost focus event?

I have a keyboard shortcut for the click handle, and the lost focus handle
does not get invoked if I use the shortcut. However, when I try the mouse to
click on the button, the lost focus is gettin triggered.

Any thoughts?

Cheers!
Nicj
Dec 13 '05 #1
0 1684

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Carlos Lozano | last post by:
Hello everybody, I Have a piece of code for a Pocket PC that has a disabled and hidden textbox control at startup. It is enabled and set visible programatically. The cursor is captured calling...
2
by: vooose | last post by:
Does anyone know the difference between these two? The doc for LostFocus says 'Occurs when the control loses focus.' whereas for Leave it says 'Occurs when the input focus leaves the control'...
4
by: Sameh Ahmed | last post by:
Hello there Is there a way to get the last control that was in focus before the current control? please note that I don't want the next or previous control in the tab order, I need the last one...
0
by: LCAdeveloper | last post by:
Another newbie question I'm afraid. When I use the .Focus() or .Select() methods to set the initial control that has focus on a form, try as I might I cannot get the control to visually indicate...
1
by: avinashraj | last post by:
Hello, I work with a third party control that provides the ability to load within it Winforms controls and providing a multi document interface such as the one in the VS.Net IDE. I find that...
1
by: =?Utf-8?B?amFtZXNAbm9zcGFtLmNvbQ==?= | last post by:
When processing the OnGotFocus event, I need to know the window/control that lost the focus. Is there a way to determint this? With MFC, you could use OnSetFocus which passed you the window that...
11
by: =?Utf-8?B?RWl0YW4=?= | last post by:
Hello, I have a WinForm application. The form has one Tab Control and one ToolStrip. I would like to know what would be the best way to detect when the user is "leaving" the Tab Control and...
3
by: Simon | last post by:
Dear reader, On the event "Lost focus" I make the ComboBox invisible but the massage pops up "You can't hide a control that has the focus." But this code is written in the "Lost focus"...
2
by: AdamOnAccess | last post by:
Hi, I'm trying to find an event in the web browser control that triggers when the user clicks on a link inside the control and arrives at a new page. My web browser control only shows 5 events...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.