Hi Guys,<br><br>i am new to wxpython an i have trouble with the menubar.<br>i tried to write a dynamic menubar that can read the itemnames from an sqlite3 database, so i can change the language very easy.<br>like this.<br>
<br><span style="font-family: courier new,monospace;"><br>def MakeMenuBar(self):<br> self.dbCursor.execute("SELECT " + self.lang[self.langSelect] +" FROM menu")</span><span style="font-family: courier new,monospace;"><br>
self.menuwords = self.dbCursor.fetchall()</span><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;"> menu = wx.Menu() ##Filemenu</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"> item = menu.Append(ID_CONNECT, "%s" %self.menuwords[3])</span><br><span style="font-family: courier new,monospace;"> .</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"> .</span><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;"> .</span><br><br>this works fine, when i draw the menu for the first time, when i want to change language in runtime, i can not get the menu to redraw.<br>
can someone help me out on this one?<br>thanks<br>heiner<br><br style="font-family: courier new,monospace;"><br><br>