Click here to Skip to main content
15,867,330 members
Please Sign up or sign in to vote.
2.20/5 (3 votes)
See more:
Hi All,
I need to select some values in a notepad or any other window without using the mouse. Using the C# code to get x position and y position to select the particular values. Please any one help me on this.

Thanks in Advance,
Thanks,
Gok
Posted
Comments
Maciej Los 29-Dec-14 7:05am    
Why?
[no name] 29-Dec-14 8:08am    
Either you use mouse -which you don't like- or a Cursor (if available, Notepad has it). If any of the existing HID does not help you have to invent a new one....e.g. the brain reader.
BillWoodruff 29-Dec-14 8:46am    
How do you know what you want to select in NotePad or any other Application ?
Member gok 30-Dec-14 2:25am    
I need select some values in a constant position(X,Y position)
Member gok 30-Dec-14 4:06am    
For Example,
"In his sophomore year, Gates devised an algorithm for pancake sorting as a solution to one of a series of unsolved problems[36] presented in a combinatorics class by Harry Lewis, one of his professors."

Need to the above 2 lines, without using mouse and also without using the keyboard events as well. Using C# code to Click, Drag and Selection is needed.

1 solution

You want a c# scrip that controls the mouse cursor?
If so look in the some functions from the user32.dll

[DllImport("user32.dll")]
static extern void mouse_event(uint dwFlags, uint dx, uint dy, uint dwData,
UIntPtr dwExtraInfo);
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900