Hi all,
Need some assistance from the programmers amongst you; I'm not so used to this windows coding malarky ;)
I've written a scrolling text plugin, which is going to form the basis for my SMS plugin. The text part is all working apart from one "small" issue:
The text strings are all stored in a listbox, for easy management and viewing. This works fine, except occasionally the SendMessage() call to get the text (LB_GETTEXT) will hang occasionally...
SendMessage(listhwnd,LB_GETTEXT,(WPARAM) CurrentMessage,(LPARAM) MessageText);
So I swapped this for SendMessageTimeout(), and sure enough it's returning 0 so it's timing out, even with large timeouts set. If I loop when a timeout occurs, it will never successfully make the call. If I skip the call until it's time to change to the next it will work fine, and the same entry will be fine next time around. It won't fail in the same place either. This means the plugin runs without crashing or hanging - but messages get randomly skipped!
Soooo, I'm trying to work out why my SendMessage() call would be timing out? It's the only thing I can't get working :( Got it working perfectly with a text file to store the messages, but obviously that makes it a bit, well, crap to look after at runtime LOL.
Regards,
Scott
Need some assistance from the programmers amongst you; I'm not so used to this windows coding malarky ;)
I've written a scrolling text plugin, which is going to form the basis for my SMS plugin. The text part is all working apart from one "small" issue:
The text strings are all stored in a listbox, for easy management and viewing. This works fine, except occasionally the SendMessage() call to get the text (LB_GETTEXT) will hang occasionally...
SendMessage(listhwnd,LB_GETTEXT,(WPARAM) CurrentMessage,(LPARAM) MessageText);
So I swapped this for SendMessageTimeout(), and sure enough it's returning 0 so it's timing out, even with large timeouts set. If I loop when a timeout occurs, it will never successfully make the call. If I skip the call until it's time to change to the next it will work fine, and the same entry will be fine next time around. It won't fail in the same place either. This means the plugin runs without crashing or hanging - but messages get randomly skipped!
Soooo, I'm trying to work out why my SendMessage() call would be timing out? It's the only thing I can't get working :( Got it working perfectly with a text file to store the messages, but obviously that makes it a bit, well, crap to look after at runtime LOL.
Regards,
Scott
Mensajes Fri 28 Dec 07 @ 3:44 am
Never mind, I've mapped the listbox to a char array and pull the data from that instead. It's a bit more limited, but it will suffice...
Mensajes Fri 28 Dec 07 @ 12:12 pm
I am wondering about your plugin SMS - is it working/ - what will it do?
Thank you
Nick
Thank you
Nick
Mensajes Sat 22 Mar 08 @ 1:16 pm