- Strength to Increase Rep
- +4
- Strength to Decrease Rep
- -1
- Upvotes Received
- 5
- Posts with Upvotes
- 5
- Upvoting Members
- 3
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
20 Posted Topics
.project is a specific file that is placed in every project. The error message makes it sound like there is a .project file in the workspace folder (which should not be there). If you navigate to the workspace directory and delete the .project file, it should work correctly.
the problem is on line # 157, you are looping from 0 to n, but are using n in the equation. So 'y = (math.exp(a) * math.e) ** (b * n)' should be 'y = (math.exp(a) * math.e) ** (b * i)'(if I understand the math correctly). you may also …
Hmmm, well the only way that I can think of off the top of my head would be to create a thread that will replace the event timer. that thread would then execute a loop that will sleep for a period of time then refresh the panel when it wakes …
you may want to try pretty print (pprint), and change the indent to whatever you need to print it out in the middle of the screen (I put a link on the bottom of this post). I have never used pprint in this way so that may or may not …
Hello jludeman! This is a really nice and simple test program, is this your first time using wxPython? Anyways, onto your questions/problems: I think in line 7 that you can use "./*.jpg" to get all of the .jpg in the current directory, but this is untested so it may not …
Where is your code for the dictionary actually located? I think the problem you are having is that you are trying to access a variable that is out of scope (and therefore doesn't exist). If you are trying to access the variable actor in the function process_file, you will not …
Is there any way to set the maximum size of a ListBox (by pixels)? I know that there is a SetMaxSize but it is not enforced.
you could just create a copy of numDivisions at the start of the function then use the copy of numDivisions whenever you want the original value.
From my understanding all you would need to do is: [CODE] self.ID_OPEN=wx.NewId() wxglade_tmp_menu.Append(self.ID_OPEN, "&Open", "", wx.ITEM_NORMAL) self.menubar.Append(wxglade_tmp_menu, menutitle) self.Bind(wx.EVT_MENU, self.ttt, id=self.ID_OPEN)[/CODE] I'm pretty sure that wx.NewId() will get a new ID that is not in use. This has always worked for me!
In line 46, you're not actually calling the method. Try self.getMemberTypeString() in line 46 instead of self.getMemberTypeString.
Have you tried looking at the python docs? [url]http://docs.python.org/[/url] A quick search there got some promising results.
Actually, cPickle does both saving and loading, with cPickle.dump and cPickle.load respectively.
You need to bind the event to the menu, not left_click. Try self.Bind(wx.EVT_MENU,self.Quit,id=201) instead of self.Bind(wx.EVT_LEFT_DOWN,self.Quit,id=201)
Your going to have to GetValue() in a function of some sort, after user input. I suggest binding to some event, either EVT_TEXT, EVT_TEXT_ENTER and GetValue() there, or place some sort of button that the user can push when they're done with input.
It's close but it's still not perfect. Try this code: [CODE]purchased = float(raw_input("Enter the total purchased: $")) if purchased >= 1000: total = purchased - ( 0.20 * purchased ) elif purchased >= 500: total = purchased - ( 0.15 * purchased ) elif purchased >= 200: total = purchased …
Check out [url]http://zetcode.com/wxpython/dialogs/[/url] . It has a brief overview of the things you can do with Dialogs.
Well, this is certainly a loaded question. First thing to do is to save two copies of the query results so there is a working copy, and an original copy. Then I would bind to EVT_LIST_END_LABEL_EDIT from the wx.ListCtrl, that way you know when a label has possibly been change. …
It sounds like you want to modify the root logger, so [ICODE]fileLogger = logging.getLogger('DIFRECFILE')[/ICODE] should be [ICODE]fileLogger = logging.getLogger('')[/ICODE] to get the root logger instead of creating a new one. Explaination: Your problem is coming from your 4th line. When you call logging.getLogger('DIFRECFILE') it will try to find a logger …
From a first glance it looks like the problem is: [ICODE]print s1[a:a+2][/ICODE] which should be [ICODE]print s1[0][a:a+2][/ICODE] because s1 is a list with only one element (the string s), and you want to output the range of characters in the string not the range of elements in the list. You …
Hey all, I just recently got into wxpython for my job and I ran into a snag. When print previewing (using the demo code) there seems to be an insane amount of pages, yet only a few of them are viewable. So my questions are: 1) Why is there an …
The End.
winmic