473,399 Members | 3,919 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,399 software developers and data experts.

Determine if there's any text selection in Windows

13
Hello,
does anyone knows how to determine if there's in Windows any selected text in active window ? Language doesn't matter, but C# would be better.
Thanks for the answer
Jul 29 '07 #1
3 1604
weaknessforcats
9,208 Expert Mod 8TB
I would start with Programming Windows by Charles Petzold.

Not all windows can have selected text. Maybe you are interested only in textbox, listbox, or editbox windows. There are SelctionStart and SelectedText properties for these kinbds of windows. Google might help here.
Jul 29 '07 #2
sin
13
I would start with Programming Windows by Charles Petzold.

Not all windows can have selected text. Maybe you are interested only in textbox, listbox, or editbox windows. There are SelctionStart and SelectedText properties for these kinbds of windows. Google might help here.
Thanks for the post.
Maybe anyone have this book in electronic format ? :)

I'm interested not only in textbox'es, but anywhere in window.
Maybe I'll change the question.
Text is only what I need, but I, first of all, want know if anything is selected at all.
Jul 30 '07 #3
weaknessforcats
9,208 Expert Mod 8TB
Almost certainly you will need to process the mouse left key down to remember a selection on a window. Not all windows let you make a selection.

Check out the Common Dialogs.
Jul 30 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Web Webon | last post by:
Hi everybody! I wonder if this is possible? I need to determine if a client is using "windows classic folders" or anything else. If I instantiate a Shell ActiveX object is there a way of...
19
by: Lauren Quantrell | last post by:
In Windows XP display Properties/Appearance users can chose between: Windows XP Style or Windows Classic Style. Is there a way in VBA to determine the user's selection? The reason: Toolbars...
1
by: Jeff S | last post by:
I would like to provide users with a text box in which they can enter a bunch of text (200 bytes or so). I would like to subsequently programmatically determine which text the user has selected. ...
7
by: Doru Roman | last post by:
Hi, What is the fastest way to evaluate manually the result in this case: int a, b, c; a = 255; b = 122; c = a & b; The only way I know is transforming each number into the binary value...
7
by: Ian F. Hood | last post by:
Hi In typically windows environments I have used: if 'Windows' in os.environ... to prove it, but now I need to properly support different environments. To do so I must accurately determine what...
1
by: mr k | last post by:
Hi, I wanted to use mail merge with forms but Text form fields are not retained during mail merge in Word, I got the code from Microsoft but it doesn't remember the text form field options such as...
3
by: Cah Sableng | last post by:
Hi all. I am new member of this group. I have a problem with currency formatter function I made. On onkeyup's method of a textfield I add function below: <snip> function formatCurrency(elm)...
14
by: > Adrian | last post by:
Is there a way of stopping text from highlighting in textbox? Many thanks, Adrian.
1
by: sin | last post by:
Hello. Sorry if I'm asking an old question, but I couldn't find it anywhere. If there is some link, please paste it. I want to know how to determine in Windows if there is any text selection in...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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
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
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new...

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.