快速登录:  

Forum: VirtualDJ Plugins

话题: Listbox Assistance....

由于该帖子已年深日久,可能包含陈旧过时或描述错误的信息。

SBDJPRO Infinity Member since 2006
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
 

发表时间 Fri 28 Dec 07 @ 3:44 am
SBDJPRO Infinity Member since 2006
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...
 

发表时间 Fri 28 Dec 07 @ 12:12 pm
npappyPRO InfinityMember since 2005
I am wondering about your plugin SMS - is it working/ - what will it do?

Thank you

Nick
 

发表时间 Sat 22 Mar 08 @ 1:16 pm


(陈旧帖子或论坛版块会自动关闭)