Re: [Tutor] [ctypes-users] Press ESC to exit()

2017-05-01 Thread eryk sun
On Mon, May 1, 2017 at 6:28 PM, Michael C wrote: > Hi all, I found out that one way to press ESC to kill the script was to use > my previous > script language, AutoHotKey and this is how it works: > > AutoHotKey code > ## function that kills the window with title

Re: [Tutor] Using Python to access .txt files stored behind a firewall as .exe files

2017-05-01 Thread Alan Gauld via Tutor
On 02/05/17 01:12, Ian Monat wrote: > 1) Use Python to download the file from the web (but not by using a > webscraper, according to Alan) Things like BeautifulSoup will help you read the HTML and extract links etc but they won't help you actually fetch the file/documents from the web site. A

Re: [Tutor] Using Python to access .txt files stored behind a firewall as .exe files

2017-05-01 Thread Ian Monat
Thank you for the reply Mats. I agree the fact that files are wrapped in an .exe is ridiculous. We're talking about a $15B company that is doing this by the way, not a ma and pa shop. Anyways... If I understand you correctly, you're saying I can: 1) Use Python to download the file from the web

Re: [Tutor] Using Python to access .txt files stored behind a firewall as .exe files

2017-05-01 Thread Mats Wichmann
On 05/01/2017 03:44 PM, Alan Gauld via Tutor wrote: > On 01/05/17 18:20, Ian Monat wrote: >> ... I've written a script using the requests module but I >> think a web scraper like Scrapy, Beautiful Soup or Selinium may be >> required. > > I'm not sure what you are looking for. Scrapy, BS etc will

Re: [Tutor] Using Python to access .txt files stored behind a firewall as .exe files

2017-05-01 Thread Ian Monat
Hi Alan, thanks for the reply. My goal is to automatically via Python download the .exe, unzip it, and place the new .txt in a folder on my OneDrive. Then I have another visualization program that loads all the .txt files in that folder and displays them in a web-dashboard. My sales team has

Re: [Tutor] Using Python to access .txt files stored behind a firewall as .exe files

2017-05-01 Thread Alan Gauld via Tutor
On 01/05/17 18:20, Ian Monat wrote: > ... I've written a script using the requests module but I > think a web scraper like Scrapy, Beautiful Soup or Selinium may be > required. I'm not sure what you are looking for. Scrapy, BS etc will help you read the HTML but not to fetch the file. Also do

Re: [Tutor] Press ESC to exit()

2017-05-01 Thread Alan Gauld via Tutor
On 01/05/17 19:28, Michael C wrote: > Hi all, I found out that one way to press ESC to kill the script was to > use my previous script language, AutoHotKey and this is how it works: > > ## When ESC is pressed, runs the function 'kill' > Esc::kill() > Is there a way to write it

[Tutor] Press ESC to exit()

2017-05-01 Thread Michael C
Hi all, I found out that one way to press ESC to kill the script was to use my previous script language, AutoHotKey and this is how it works: AutoHotKey code ## function that kills the window with title '*Python 3.6.1 Shell*' kill() { WinKill, *Python 3.6.1 Shell* } ## When ESC is pressed,

[Tutor] Press ESC to exit()

2017-05-01 Thread Michael C
Hi all, I am trying to write a script to exit itself when ESC is pressed. I have found several answers regarding it such as this: http://stackoverflow.com/questions/43709710/push-esc- to-terminate-python-script?noredirect=1#comment74464169_43709710 But those only work when the program goes to

[Tutor] Using Python to access .txt files stored behind a firewall as .exe files

2017-05-01 Thread Ian Monat
I've got a Python project that I'd love some help on from a Python developer who is well versed at web scraping or requests. I work for a supplier, and we use a distributor to sell our products to retailers. The distributor has a reporting website that requires a login. >From that home / login

Re: [Tutor] Fwd: Re: Python 3.6 Extract Floating Point Data from a Text File

2017-05-01 Thread Alan Gauld via Tutor
On 01/05/17 15:54, Stephen P. Molnar wrote: > Unfortunately, I'm still missing something. Here is my latest attempt > to incorporate your solution: > name = input("Enter Molecule ID: ") > name = str(name) you don't need the str() since input() always returns whatever string the user enters. >

Re: [Tutor] Another set question

2017-05-01 Thread Phil
On Sun, 30 Apr 2017 15:58:13 +0100 Alan Gauld via Tutor wrote: > I would probably combine both such that for each cell you > have a tuple containing the given number and the set of > candidates. In some cases the number may be a sentinel > (such as -1) to indicate no number