473,407 Members | 2,306 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,407 software developers and data experts.

Best way to see if CTRL is being pressed?

In an app, I want to see if the user has the CTRL key pressed from within a
TreeView BeforeUpdate event handler... what's the best way to do this?

TIA,
-B

Nov 13 '05 #1
2 5582
Hi Baseman,

Control.ModifierKeys should give you this info.

Miha

"Baseman" <no****************@hotmail.com> wrote in message
news:xVxRa.7660$zd4.6709@lakeread02...
In an app, I want to see if the user has the CTRL key pressed from within a TreeView BeforeUpdate event handler... what's the best way to do this?

TIA,
-B

Nov 13 '05 #2
Thanks! That did the trick.

Regards,
-B

Miha Markic wrote:
Hi Baseman,

Control.ModifierKeys should give you this info.

Miha

"Baseman" <no****************@hotmail.com> wrote in message
news:xVxRa.7660$zd4.6709@lakeread02...
In an app, I want to see if the user has the CTRL key pressed from within


a
TreeView BeforeUpdate event handler... what's the best way to do this?

TIA,
-B



Nov 13 '05 #3

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

Similar topics

3
by: Mr. x | last post by:
Hello, I want to capture the event when the <ctrl> key is pressed. How can I do that ? Thanks :)
10
by: chirs | last post by:
I have a code to disable ctrl-v (paste) on the 2nd box. The problem is that when I type ctrl-v, the text shows, then disappear after I release ctrl-v. How can I make it not to show in the box. In...
8
by: MLH | last post by:
I use a mouse-down procedure to trap right mouse clicks and CTRL-Right mouse clicks. Running the procedure must put honey or some other sticky substance into my keyboard because subsequent...
1
by: Pedro Graca | last post by:
Well ... I've been using Windows for a long time before I switched to Linux. I'm very used to type CTRL-ALT-DEL everytime I'm leaving my computer or arriving to it. It's hapenned _twice_ (in the...
3
by: Stefan | last post by:
Hy, i have an app and i must disable this combination: ALT+F4; CTRL+ALT+DEL; CTRL+ESC;ALT+TAB like this: i find something on Internet and i can block ALT+F4 protected override...
3
by: Glen Hong | last post by:
I have set up a hotkey using RegisterHotKey API function for Ctrl-Tab. Firstly, I can rap this when Ctrl-Tab is pressed however if I want to add an addition hotkey how can I distinguish between...
2
by: Du | last post by:
How to tell if the Ctrl key is pressed without being inside a keypress/keyup/keydown event? I want distinguish between a "click" and a "ctrl+click" on a button. any suggestion? thanks
4
by: Tom | last post by:
Hi, I would like to know wether the Ctrl-key is pressed down when i click a button on my win form. how can i do this? tia, Tom
5
by: Sharon | last post by:
I’m using the DataGrid control. The DataGrid allow select all by clicking on CTRL+A keys. I need to catch this keys event, so I tried using the KeyDown event, but only when the CTRL is pressed I...
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: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.