X-Received: by 10.224.36.66 with SMTP id s2mr7372200qad.6.1367249510591; Mon, 29 Apr 2013 08:31:50 -0700 (PDT) X-Received: by 10.49.35.129 with SMTP id h1mr6525qej.28.1367249510471; Mon, 29 Apr 2013 08:31:50 -0700 (PDT) Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder2.hal-mli.net!border3.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!s14no812804qam.0!news-out.google.com!ef9ni28916qab.0!nntp.google.com!s14no812800qam.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.python Date: Mon, 29 Apr 2013 08:31:50 -0700 (PDT) In-Reply-To: <7df67006-2176-42cb-a8ce-95a72339e7e2@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=88.169.159.132; posting-account=6PGjhQoAAABeR_4Ohs9W3d5ZVdcv-J53 NNTP-Posting-Host: 88.169.159.132 References: <7df67006-2176-42cb-a8ce-95a72339e7e2@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Unwanted window spawns when using Tkinter with multiprocessing. From: alternative00@rocketmail.com Injection-Date: Mon, 29 Apr 2013 15:31:50 +0000 Content-Type: text/plain; charset=ISO-8859-1 Lines: 39 Xref: csiph.com comp.lang.python:44506 My full code is : #Import from tkinter import * import wave import winsound import multiprocessing #Initialisation fenetre=Tk() frame = Frame(fenetre, width=200, height=100) instance = 'Instance' #Fonctions def key(event): instance = 'Instance' hitkey = event.char instance = multiprocessing.Process(target=player, args=(hitkey,)) instance.start() def player(hitkey): winsound.PlaySound(hitkey + '.wav', winsound.SND_FILENAME|winsound.SND_NOWAIT|winsound.SND_ASYNC) #TK frame.focus_set() frame.bind("", key) frame.pack() fenetre.mainloop() The problem is that I don't know where to put that clause.