win32lib suggestion
- Posted by tone.skoda at zapo.net Nov 20, 2001
- 384 views
i used this function to delete all items in treeview: Void = sendMessage (treeview, TVM_DELETEITEM, 0, TVI_ROOT) but because of it my program was behaving very strange, and thats why i put off working on it for quite some time now i finally found out what was wrong: i should have used Void = deleteItem (treeview, -1) instead. So: there should be a warning message box when programmer uses Void = sendMessage (treeview, TVM_DELETEITEM, 0, TVI_ROOT) or some similar shit which can cause bugs, at least in debug mode (which i think win32lib should have). like this: if msg = TVM_DELETEITEM then if lParam = TVI_ROOT then message_box ("Warning: using TVM_DELETEITEM and TVI_ROOT can cause bugs in your program!", "", 0) end if end if