[Python.NET] winForms, threading and dragdrop ?

2005-09-11 Thread Guy Robinson
From the attached code.With AllowDrop = True I get a .NET error as follows: System.InvalidOperationException: DragDrop registration failed. ---> System.Threading.ThreadStateException: The current thread must set to Single Thread Apartment (STA) mode before OLE calls can be made. Ensure that yo

[Python.NET] binding python objects to treenodes

2005-09-11 Thread Guy Robinson
Hello, Is there a way to bind a python object to a treeView node? I have the following treenode based class: class dataNode(WinForms.TreeNode): def __init__(self,name,total): self.Text = name self.Total = total And I add the node as such: self.treeView1.Nodes.Add(dataNo