Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8994511
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T23:26:55+00:00 2026-06-15T23:26:55+00:00

I am writing a simple C# program in which when I press Ctrl +

  • 0

I am writing a simple C# program in which when I press Ctrl+G I want my program to automatically delete the character directly left of the cursor in any program (ex: chrome browser, word document, powerpoint document, etc…).

I have installed a global hook for Ctrl+G and it works fine.
I am using a keyboard simulator that I found on Code Project.

My issue is that when I simulate a backspace like:

KeyboardSimulator.KeyPress(Keys.Back);

the entire word is deleted instead of just the character to the left of the cursor.

For example, if I am in a Microsoft Word document with the following line of text:

"Happy new year"

and my cursor is at the end of "year", then when I press Ctrl+G, my program deletes "year" and puts the cursor just to the right of "new" — instead of just deleting the letter "r" in "year".

I have tried other simulators as well with the same result.

Does anyone have a solution or know what I am doing incorrectly?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T23:26:56+00:00Added an answer on June 15, 2026 at 11:26 pm

    Apparently, Ctrl+Backspace commonly means delete the entire word in Windows.

    So when you press Ctrl+G, and your hook simulates the Backspace key, the program instead sees Ctrl+Backspace because the Ctrl key is down.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am writing simple program for my Ubuntu 10.04. I want to see which
I am writing a simple program, which is trying to find next palindrome number
So I was writing this simple program to calculate the day of any date
I'm writing a very simple program, which prints color of selected pixel. Here is
I am writing a simple program in which parent and child process are alternatively
When writing a simple program for a POSIX-compliant OS which accepts input and produces
Iam writing a simple Java program for an assignment,which implements a library system using
I'm writing a simple program in C which opens an internet browser using the
I'm writing a simple program in Java which includes a KeyListener with the following
I'm writing a simple plugin based program. I have an interface IPlugin which has

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.