BitRot Posted September 27, 2006 Share Posted September 27, 2006 Hello All, I'm currently trying to change the mouse-cursor to something else than the standard arrow, depending on certain conditions. Currently I load the mouse-cursor I want, using User32.dll's "LoadCursorA" function, and than apply it by using "SetCursor" function. The problem is that whenever I move the mouse its appearance gets set back to the standard arrow. An attempt to set the arrows appearance in every step results in annoying flickering between both the origional and the desired one. Has anyone got an idea how to change the mouse-cursor (that does not result in such a flicker) ? Link to comment Share on other sites More sharing options...
Uten Posted September 27, 2006 Share Posted September 27, 2006 I'm not sure I follow you but is this what your after? From the help file GUISetCursor ( [cursorID [, override [, winhandle]]] ) Please keep your sig. small! Use the help file. Search the forum. Then ask unresolved questions :) Script plugin demo, Simple Trace udf, TrayMenuEx udf, IOChatter demo, freebasic multithreaded dll sample, PostMessage, Aspell, Code profiling Link to comment Share on other sites More sharing options...
BitRot Posted September 27, 2006 Author Share Posted September 27, 2006 (edited) I'm not sure I follow you but is this what your after? From the help fileGUISetCursor ( [cursorID [, override [, winhandle]]] )Grrr.... Yes, that pretty-much looks like it. I must have seen, but not recognised it. I did find the "MouseGetCursor", but not "MouseSetCursor", nor was the above command mentioned in the "related" section. Any chance that I can use other cursor ID's than the 16 named there ? Currently I'm using cursor-ID's 32654 thru 32662, the scroll-images that appear when you press the middle mouse-button in a document. I like to have those single-direction pointers, instead of the default double-directions Windows (and therefore AutoIt) offers. Edited September 27, 2006 by BitRot Link to comment Share on other sites More sharing options...
Uten Posted September 27, 2006 Share Posted September 27, 2006 Supose you can load your own cursors and set those (I could in VB6 so why not in AutoIt?). I don't recal how it was done thought (but it was through th ewindows API) Please keep your sig. small! Use the help file. Search the forum. Then ask unresolved questions :) Script plugin demo, Simple Trace udf, TrayMenuEx udf, IOChatter demo, freebasic multithreaded dll sample, PostMessage, Aspell, Code profiling Link to comment Share on other sites More sharing options...
BitRot Posted September 28, 2006 Author Share Posted September 28, 2006 Supose you can load your own cursors and set those (I could in VB6 so why not in AutoIt?). I don't recal how it was done thoughtI've got no problem loading those cursors (allready did that). The current problem is that AI's cursor-settings only go from 0 to 16, and do not seem to accept any other values (I allready tried).Setting those loaded cursors by way of a DLL-function causes them to battle with AI's own cursor, with the beforementioned flickering as a result. Link to comment Share on other sites More sharing options...
Uten Posted September 28, 2006 Share Posted September 28, 2006 Sorry, but I have no solution for you at the moment. Maybe someone else have? Please keep your sig. small! Use the help file. Search the forum. Then ask unresolved questions :) Script plugin demo, Simple Trace udf, TrayMenuEx udf, IOChatter demo, freebasic multithreaded dll sample, PostMessage, Aspell, Code profiling Link to comment Share on other sites More sharing options...
BitRot Posted September 28, 2006 Author Share Posted September 28, 2006 <snip code>Sneaky ! First setting your own cursor, and than simply ignore any requests that attempt to change it. I don't think I would have ever thought of a solution like that. Thanks. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now