Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. How to Change the Mouse Cursor outside the WinForm using C#?

How to Change the Mouse Cursor outside the WinForm using C#?

Scheduled Pinned Locked Moved C#
csharpwindows-admintutorialquestion
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • K Offline
    K Offline
    Khanh p
    wrote on last edited by
    #1

    Hello All, I am working on a school project; using c# to create a windows form application to modify Window's mouse cursor. I have tried many attempts using cursor class that MSDN provided. However, I was not successfully done what I'd like to do for this project. I'd like to know if there is anyway that I can change the arrow cursor to my custom cursor out side the application form (When the application actively in the foreground or sit in the system tray)? I only able to change the cursor when the mouse is actively within the application form, but when I move the mouse to the desktop (outside the application form) it would change to a default window cursors. Please let me know if I can change the window's mouse cursor permanently once my code is active or any alternative i.e.: change the registry keys to make this happen. Many thanks, Khanh.p

    C T 2 Replies Last reply
    0
    • K Khanh p

      Hello All, I am working on a school project; using c# to create a windows form application to modify Window's mouse cursor. I have tried many attempts using cursor class that MSDN provided. However, I was not successfully done what I'd like to do for this project. I'd like to know if there is anyway that I can change the arrow cursor to my custom cursor out side the application form (When the application actively in the foreground or sit in the system tray)? I only able to change the cursor when the mouse is actively within the application form, but when I move the mouse to the desktop (outside the application form) it would change to a default window cursors. Please let me know if I can change the window's mouse cursor permanently once my code is active or any alternative i.e.: change the registry keys to make this happen. Many thanks, Khanh.p

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      Once the cursor is over another program, it can change the cursor, so the answer is probably no. Christian Graus - Microsoft MVP - C++

      1 Reply Last reply
      0
      • K Khanh p

        Hello All, I am working on a school project; using c# to create a windows form application to modify Window's mouse cursor. I have tried many attempts using cursor class that MSDN provided. However, I was not successfully done what I'd like to do for this project. I'd like to know if there is anyway that I can change the arrow cursor to my custom cursor out side the application form (When the application actively in the foreground or sit in the system tray)? I only able to change the cursor when the mouse is actively within the application form, but when I move the mouse to the desktop (outside the application form) it would change to a default window cursors. Please let me know if I can change the window's mouse cursor permanently once my code is active or any alternative i.e.: change the registry keys to make this happen. Many thanks, Khanh.p

        T Offline
        T Offline
        Tom Larsen
        wrote on last edited by
        #3

        Considering that those "other applications" may want to change the cursor for various UI hints and reasons, why would your cursor overide their cursor?? In general it is not good usibility alter cursors outside of your application. If you want to change a cursor for all applications use a theme.

        K 1 Reply Last reply
        0
        • T Tom Larsen

          Considering that those "other applications" may want to change the cursor for various UI hints and reasons, why would your cursor overide their cursor?? In general it is not good usibility alter cursors outside of your application. If you want to change a cursor for all applications use a theme.

          K Offline
          K Offline
          Khanh p
          wrote on last edited by
          #4

          This is only a School project, and I like to know if this is possible in anyway. I am not trying to overwrite any other applications. However, I might take a wrong approach for this project. :( If not possible, I may need to reconsider my project. :) Thanks for the reply All. Khanh.p

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups