Forum: Python Jan 15th, 2009 |
| Replies: 8 Views: 1,634 You may find this helpful
http://www.voidspace.org.uk/python/movpy/movableidle.html
Chris |
Forum: Python Dec 8th, 2008 |
| Replies: 15 Views: 886 Make the delay bigger, thats the idea behind wx.media.MEDIA_LOADED event it triggers when the media is loaded and only then, unfortunately it seems poorly documented.
Chris |
Forum: Python Dec 7th, 2008 |
| Replies: 15 Views: 886 OK, here is my sugestion...please bare in mind i know nothing about Python GUI and event handling so i cannot really provide any sort of code examples.
You need to ensure that the media has loaded... |
Forum: Python Dec 6th, 2008 |
| Replies: 4 Views: 893 This is a common problem, it seems you have to manually include the mail module, this link maybe of help to you
http://stackoverflow.com/questions/169897/how-to-package-twisted-program-with-py2exe
... |
Forum: Python Dec 1st, 2008 |
| Replies: 7 Views: 548 Hehe glad you got it working.
To think i've only ever downloaded wxPython & created a basic window with a listbox on it. I've never even added data to that list box hehe. Ah well it's all good... |
Forum: Python Dec 1st, 2008 |
| Replies: 7 Views: 548 Hmm thats odd. I did think about the SendKeys module but i wasn't sure if you wanted to use it or not.
Addressing your other issue, did you try using... |
Forum: Python Dec 1st, 2008 |
| Replies: 7 Views: 548 Hmm i see your point, i cannot find a method of creating a wxKeyEvent event which is what is required for EmulateKeyPress().
Another possible solution would be to use
... |
Forum: Python Nov 30th, 2008 |
| Replies: 7 Views: 548 Could you use EmulateKeyPress() after that to send a backspace to it?
Chris |
Forum: Python Nov 29th, 2008 |
| Replies: 2 Views: 526 Yes there is it's pretty simple too
mylist = ['blue', 'red', 'green', 'green', 'red', 'red']
for word in set(mylist):
print word, "appears", mylist.count(word), "times."
Hope that... |
Forum: Python Oct 5th, 2008 |
| Replies: 3 Views: 529 I'm not sure if i understood you but i think you are after something like this, windows only all i could find
http://www.rutherfurd.net/python/sendkeys/ |
Forum: Python Jun 4th, 2008 |
| Replies: 18 Views: 1,526 Tkinter is the easier, and has one big advantage; its standard.
However i personally find hat wxPython is better although slightly harder to learn.
Chris |
Forum: Python Jun 4th, 2008 |
| Replies: 7 Views: 1,709 m= start[0]*60+start[1]
n= finish[0]*60+finish[1]
here there is a problem, start[0] refers to the first character in the string start. so from your exmaple of 14, 12 start[0] would be 1. and... |
Forum: Python May 20th, 2008 |
| Replies: 4 Views: 582 for word in list:
print word+",",
or did i just miss what you asked? |
Forum: Python May 20th, 2008 |
| Replies: 7 Views: 669 def dela(c):
sum=0
pile = []
while sum < c:
b = random.randrange (1, 10 - sum + 1)
pile.append(b)
sum += 1
print pile,sum
return sum, pile... |
Forum: Python May 20th, 2008 |
| Replies: 7 Views: 669 the first print is showing 2 different objects.
The second print is showing 1 object.
Read about lists & tuples, embedding in particular, this may help you understand
Chris |
Forum: Python May 20th, 2008 |
| Replies: 8 Views: 748 It works perfectly, you just need to read about unicode(UTF-8) encoding and other data encoding. By default you are using ascii....which arabic characters do not fall under.
Chris |
Forum: Python May 20th, 2008 |
| Replies: 6 Views: 593 Indeed, after the def statement everything indented is included in the function for example.
def myfunc():
#in function
#still in function
#when in a function you can use normal... |
Forum: Python May 19th, 2008 |
| Replies: 6 Views: 593 what you saying is you want to use the same bit of code over and over?
sorry if this is not what you are asking
if so then you use a function
def myFunction(param1, param2):
print param1
... |
Forum: Python May 19th, 2008 |
| Replies: 3 Views: 715 mywxpythonscript.pyw
this will then run with pythonw.exe which doesn't run the commandline window
Chris |
Forum: Python May 19th, 2008 |
| Replies: 4 Views: 2,393 Simple read the use file.readlines() on both files to give you 2 arrays
so something like this
f1 = open("file1.txt", "r")
f2 = open("file2.txt", "r")
fileOne = f1.readlines()
fileTwo =... |
Forum: Python May 18th, 2008 |
| Replies: 2 Views: 1,007 One way is to raise you own exception and then catch it with a break.
class myException(Exception): pass
w = input("Enter width")
h = input("Enter height")
for x in range(0,w):
for y... |
Forum: Python May 18th, 2008 |
| Replies: 8 Views: 919 Hope it works for you, like i say we can always change it.
Congratulations, with the new born.
Chris |
Forum: Python May 18th, 2008 |
| Replies: 8 Views: 919 lol thanks for pointing that out, i've updated it to avoid confusion. In actually fact although it is bad, in that example it will work fine. The only time you will have a problem with that is if you... |
Forum: Python May 18th, 2008 |
| Replies: 8 Views: 919 import os
folderA = []
for path, dirs, files in os.walk("C:\\Folder A"):
for f in files:
folderA.append(f)
i = 0
for path, dirs, files in os.walk("C:\\Folder B"):
for f in... |