title: Pass a counter from a python thread to a wxpython gage?
body: <p>I am trying to pass a counter from a python COM thread back into a wxpython tabpanel.  Anyone have a solution that would work.  Some of my code below:</p>
  
  <p>This class is seperate from my wxPython code but is called out and data sent to this thread.</p>
  
  <p><code>class Log_COM_thread(Thread):
  ............
      def run(self):<br>
          .............<br>
          int_log_cnt = int_log_cnt + 1<br>
          int_log.TabPanel.gauge.SetValue(int_log_cnt)<br>
              if int_log_cnt == 64:<br>
                  int_log.TabPanel.Int_Log_Status.SetLabel('Extraction Complete')</code>  </p>
  
  <p>The seperate module, int_log, this counter value is being sent to is called out like this:</p>
  
  <p><code>class TabPanel(wx.Panel):<br>
      def __init__(self, parent):<br>
          self.gauge = wx.Gauge(self, range=72, size=(250, 25))<br>
          .....and then more wxpython code.</code>  </p>
  
  <p>The error I run into is:</p>
  
  <p><code>Exception in thread Thread-8:<br>
  Traceback (most recent call last):<br>
    File "F:\Python27\lib\threading.py", line 551, in __bootstrap_inner
  self.run()<br>
    File "F:\Documents and Settings\swhite\Desktop\OG GUI Working Jan 13\nbm.py", line 267, in run<br>
      int_log.TabPanel.gauge.SetValue(int_log_cnt)<br>
  AttributeError: type object 'TabPanel' has no attribute 'gauge'</code>  </p>
  
  <p>How would I send my counter back to that gauge in wxpython from my external thread.  Any help in direction of how to do this would be extremely helpful.   </p>