Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

C# Mouse point place?

Posted on 2009-04-24
3
Medium Priority
?
725 Views
Last Modified: 2013-12-17
I have 1 textbox with tabIndex =0;

I have 1 button, how can I do to move mouse point to tabIndex =0 when I click the button?

Please help me.
0
Comment
Question by:Mr_Bach
3 Comments
 
LVL 26

Accepted Solution

by:
Anurag Thakur earned 2000 total points
ID: 24231035
do you want to move the cursor to the text box or the mouse pointer to the text box when you click the button
to do the first its quite simple as you can do txtBox.Focus(); or something like that
0
 
LVL 3

Expert Comment

by:Aleksei_Malkov
ID: 24231375
For moving mouse pointer use System.Windows.Forms.Cursor class
Position property.

Cursor.Position = new Point (X, Y);

If you'd like to switch focus - just call textBox.Focus() method
0
 
LVL 15

Expert Comment

by:oobayly
ID: 24231842
I agree with Aleksei_Malkov.
Also, moving the mouse cursor without input (I'm not counting the button click here) is not user friendly. As a user I should control the mouse position, not the application.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
In real business world data are crucial and sometimes data are shared among different information systems. Hence, an agreeable file transfer protocol need to be established.
Integration Management Part 2
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Suggested Courses

578 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