Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!news.stack.nl!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.006 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'subject:Windows': 0.02; 'example:': 0.03; 'finally:': 0.07; 'url:msdn': 0.07; 'subject:using': 0.09; 'try:': 0.09; 'python': 0.11; 'gui': 0.12; 'input:': 0.16; 'patil': 0.16; 'subject:GUI': 0.16; 'subject:python': 0.16; 'wrote:': 0.18; 'minutes.': 0.22; 'error': 0.23; 'excel': 0.26; 'header:In-Reply-To:1': 0.27; 'idea': 0.28; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; 'this.': 0.32; 'running': 0.33; 'received:google.com': 0.35; 'false': 0.36; 'doing': 0.36; 'url:microsoft': 0.37; 'url:library': 0.38; 'url:office': 0.38; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'read': 0.60; 'hope': 0.61; 'took': 0.61; 'more': 0.64; 'skip:w 40': 0.68; 'url:en-us': 0.68; 'excel,': 0.84; 'excel.': 0.84 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=8nGGRGIItelXFQs2WNqi4+hvh7AdyPein9fMWtE0dVs=; b=xdOVrMjHwwysiZwrst3++d9kg5T3ToxZ+3nm+JKjHYUD+4vzEPAFKGFH4p4u+oH67L NdSRMB6PrWjxSrUIeigeiVKR3fWtJfYPr8bqhLx7ntVoVqCV7xJX0Rz/NbfZLWFKH3+f qFBJuEQ0KqBZX1pKjsm9fF++cgKieYGGO9NuhKtTQpmCeprRk+kgillQJgRyfBtvuAPj o5JBIg16q0hOwoEZ6A2e/PPe0dWwWFAEcTLl5JL+MZIb8HkEt4OkhM+nSp9w33SG5gEb M/PCa1++CAwFwDTZXV4VJDDP0ahJuB/vcJodaVymaBRnKhbZAi3f5TbVg1cakIk+SV8u S/nQ== X-Received: by 10.236.65.227 with SMTP id f63mr4928421yhd.13.1401779418571; Tue, 03 Jun 2014 00:10:18 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: <0d04724b-d800-407f-9614-1a86c4a58769@googlegroups.com> From: Ian Kelly Date: Tue, 3 Jun 2014 01:09:38 -0600 Subject: Re: Lock Windows Screen GUI using python To: Python Content-Type: text/plain; charset=UTF-8 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 22 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1401779421 news.xs4all.nl 2845 [2001:888:2000:d::a6]:45288 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:72483 On Tue, Jun 3, 2014 at 12:40 AM, Jaydeep Patil wrote: > Hi Lan, > > Currently I am doing some automation in python excel. It read the data & plots number of graphs. It took more than 20 minutes. So while running my python program if user clicks on excel, error came. > > So just i want to lock GUI not workstation. > > I hope you understand this. > > Let me know if you have any idea about it. You can set the Application.Interactive property on Excel to block user input: http://msdn.microsoft.com/en-us/library/office/ff841248(v=office.15).aspx Example: excel_app = win32com.client.Dispatch("Excel.Application") excel_app.Interactive = False try: # Do some automation... finally: excel_app.Interactive = True