Jump to content
Sign in to follow this  
Andreik

Set Mouse Cursor for my GUI

Recommended Posts

Andreik

I created a mouse cursor and I do not know how to use it.

GuiSetCursor is only for the 16 standard cursors but I want to set a different cursor.

Does anyone know how can I do that?


When the words fail... music speaks

Share this post


Link to post
Share on other sites
Andreik

I found this functions for cursors created by GaryFrost, but when I move the mouse, my cursor starts to flick. How can I fix this?

#include <Cursor.au3>

$hCursor = _Cursor_LoadFromFile(@ScriptDir & "\Psi.cur")
$GUI = GUICreate("TEST",400,400)
GUISetState()

While 1
    _Cursor_Set($hCursor)
    $MSG = GUIGetMsg()
    If $MSG = -3 Then
        _Cursor_Destroy($hCursor)
        Exit
    EndIf
    Sleep(15)
WEnd

When the words fail... music speaks

Share this post


Link to post
Share on other sites
TehWhale

Call cursor set before your loop, and not in your loop. :mellow:

Share this post


Link to post
Share on other sites
Andreik

Call cursor set before your loop, and not in your loop. :mellow:

Did not get the idea. If put before the loop, the cursor will not appear at all.

Thanks anyway.


When the words fail... music speaks

Share this post


Link to post
Share on other sites
TehWhale

Did not get the idea. If put before the loop, the cursor will not appear at all.

Thanks anyway.

Oh, I've never used that before, and it just though that maybe it stayed until you called that. Sorry I wasn't much of a help.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.