Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #51744 > unrolled thread
| Started by | hambergcfa@gmail.com |
|---|---|
| First post | 2013-08-01 10:31 -0700 |
| Last post | 2013-08-02 23:30 +0100 |
| Articles | 8 — 4 participants |
Back to article view | Back to comp.lang.python
How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro hambergcfa@gmail.com - 2013-08-01 10:31 -0700
Re: How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro Chris Angelico <rosuav@gmail.com> - 2013-08-01 18:47 +0100
Re: How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro hambergcfa@gmail.com - 2013-08-01 11:08 -0700
Re: How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro Chris Angelico <rosuav@gmail.com> - 2013-08-01 19:32 +0100
Re: How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro hambergcfa@gmail.com - 2013-08-02 11:18 -0700
Re: How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro Joel Goldstick <joel.goldstick@gmail.com> - 2013-08-02 14:55 -0400
Re: How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro Skip Montanaro <skip@pobox.com> - 2013-08-02 14:25 -0500
Re: How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro Chris Angelico <rosuav@gmail.com> - 2013-08-02 23:30 +0100
| From | hambergcfa@gmail.com |
|---|---|
| Date | 2013-08-01 10:31 -0700 |
| Subject | How to use Python to open Unread message(s) in specific Outlook folder, clicking a hyperlink within the email message to a secure login window, entering password to download .csv file, run Excel macro |
| Message-ID | <1d7bfd13-52d0-4d2b-8f7f-e117cdec2a5b@googlegroups.com> |
Entire Project
I am very new to Python and realize my subject line is more than a mouthful and the best way to tackle this project may be to break it down into smaller projects; but I wanted to let you know what my entire project is in the event there is/are shortcuts or more reliable ways to go about what I'm trying to accomplish.
Details
Every morning I receive three emails (three different subject lines) in the same Sub-Folder ("POINT") under Folder ("Reports") in my Inbox in Outlook. Each email has two secure hyperlinks, one provides me with a site to register and the other provides a window for me to enter my password to download a .csv file.
Is there code that will open the "Unread" emails in the "POINT" folder, click the appropriate hyperlink, enter my password (the same for all emails), and download the .csv file and then run an Excel macro? I've already created the Excel macro, one for each of the different files I'm downloading.
I have no idea where to begin with Outlook and have reservations as to whether or not this is even possible.
[toc] | [next] | [standalone]
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2013-08-01 18:47 +0100 |
| Message-ID | <mailman.84.1375379259.1251.python-list@python.org> |
| In reply to | #51744 |
On Thu, Aug 1, 2013 at 6:31 PM, <hambergcfa@gmail.com> wrote:
> Details
> Every morning I receive three emails (three different subject lines) in the same Sub-Folder ("POINT") under Folder ("Reports") in my Inbox in Outlook. Each email has two secure hyperlinks, one provides me with a site to register and the other provides a window for me to enter my password to download a .csv file.
>
> Is there code that will open the "Unread" emails in the "POINT" folder, click the appropriate hyperlink, enter my password (the same for all emails), and download the .csv file and then run an Excel macro? I've already created the Excel macro, one for each of the different files I'm downloading.
Okay, taking a few steps back here.
1) You receive an email
2) That email has two URLs in it ("secure hyperlinks" means they begin
https:// ?)
3) You choose one of them as being "appropriate" - is it always the second?
4) You download the document at that URL, which requires a password
5) You then run some sort of alteration on the resulting CSV file.
Please correct me on anything I've misunderstood.
Python can certainly do all of these steps, with the possible
exception of fetching the email. Dividing the problem up into separate
steps will make the solving of it easier.
ChrisA
[toc] | [prev] | [next] | [standalone]
| From | hambergcfa@gmail.com |
|---|---|
| Date | 2013-08-01 11:08 -0700 |
| Message-ID | <e433f87d-7bc1-4c04-b27d-f57465f3022d@googlegroups.com> |
| In reply to | #51747 |
On Thursday, August 1, 2013 1:47:37 PM UTC-4, Chris Angelico wrote:
> On Thu, Aug 1, 2013 at 6:31 PM, <hambergcfa@gmail.com> wrote:
>
> > Details
>
> > Every morning I receive three emails (three different subject lines) in the same Sub-Folder ("POINT") under Folder ("Reports") in my Inbox in Outlook. Each email has two secure hyperlinks, one provides me with a site to register and the other provides a window for me to enter my password to download a .csv file.
>
> >
>
> > Is there code that will open the "Unread" emails in the "POINT" folder, click the appropriate hyperlink, enter my password (the same for all emails), and download the .csv file and then run an Excel macro? I've already created the Excel macro, one for each of the different files I'm downloading.
>
>
>
> Okay, taking a few steps back here.
>
>
>
> 1) You receive an email
>
> 2) That email has two URLs in it ("secure hyperlinks" means they begin
>
> https:// ?)
>
> 3) You choose one of them as being "appropriate" - is it always the second?
>
> 4) You download the document at that URL, which requires a password
>
> 5) You then run some sort of alteration on the resulting CSV file.
>
>
>
> Please correct me on anything I've misunderstood.
>
>
>
> Python can certainly do all of these steps, with the possible
>
> exception of fetching the email. Dividing the problem up into separate
>
> steps will make the solving of it easier.
>
>
>
> ChrisA
Thanks a lot ChrisA! You are correct with everything except that the login hyperlink is always the first link and the second one is the link to register.
[toc] | [prev] | [next] | [standalone]
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2013-08-01 19:32 +0100 |
| Message-ID | <mailman.90.1375381978.1251.python-list@python.org> |
| In reply to | #51751 |
On Thu, Aug 1, 2013 at 7:08 PM, <hambergcfa@gmail.com> wrote:
>> 1) You receive an email
>>
>> 2) That email has two URLs in it ("secure hyperlinks" means they begin
>>
>> https:// ?)
>>
>> 3) You choose one of them as being "appropriate" - is it always the second?
>>
>> 4) You download the document at that URL, which requires a password
>>
>> 5) You then run some sort of alteration on the resulting CSV file.
>>
>>
>>
>> Please correct me on anything I've misunderstood.
>>
>>
>>
>> Python can certainly do all of these steps, with the possible
>>
>> exception of fetching the email. Dividing the problem up into separate
>>
>> steps will make the solving of it easier.
>>
>>
>>
>> ChrisA
>
> Thanks a lot ChrisA! You are correct with everything except that the login hyperlink is always the first link and the second one is the link to register.
Okay!
(Digression: You seem to be using Google Groups. Please read
http://wiki.python.org/moin/GoogleGroupsPython before posting further,
to avoid antagonizing the list's best responders.)
The first step is to figure out how to retrieve the email. You may
want to tweak your setup to make this easier. The next thing I'd do
would be to port the macro to Python. Everything in between is fairly
easy.
ChrisA
[toc] | [prev] | [next] | [standalone]
| From | hambergcfa@gmail.com |
|---|---|
| Date | 2013-08-02 11:18 -0700 |
| Message-ID | <54f5caea-6526-4f8f-808f-3da46824dc1d@googlegroups.com> |
| In reply to | #51754 |
On Thursday, August 1, 2013 2:32:55 PM UTC-4, Chris Angelico wrote:
On Thu, Aug 1, 2013 at 7:08 PM, <hambergcfa@gmail.com> wrote:
1) You receive an email
2) That email has two URLs in it ("secure hyperlinks" means they begin
https:// ?)
3) You choose one of them as being "appropriate" - is it always the second?
4) You download the document at that URL, which requires a password
5) You then run some sort of alteration on the resulting CSV file.
Please correct me on anything I've misunderstood.
Python can certainly do all of these steps, with the possible
exception of fetching the email. Dividing the problem up into separate
steps will make the solving of it easier.
ChrisA
Thanks a lot ChrisA! You are correct with everything except that the login hyperlink is always the first link and the second one is the link to register.
Okay!
Digression: You seem to be using Google Groups. Please read
http://wiki.python.org/moin/GoogleGroupsPython before posting further,
to avoid antagonizing the list's best responders.)
The first step is to figure out how to retrieve the email. You may
want to tweak your setup to make this easier. The next thing I'd do
would be to port the macro to Python. Everything in between is fairly
easy.
ChrisA
Thanks for the heads up ChrisA! How should I tweak my setup to make it easier to retrieve my email? I hope I'm doing this reply correctly.
[toc] | [prev] | [next] | [standalone]
| From | Joel Goldstick <joel.goldstick@gmail.com> |
|---|---|
| Date | 2013-08-02 14:55 -0400 |
| Message-ID | <mailman.130.1375469743.1251.python-list@python.org> |
| In reply to | #51820 |
On Fri, Aug 2, 2013 at 2:18 PM, <hambergcfa@gmail.com> wrote:
> On Thursday, August 1, 2013 2:32:55 PM UTC-4, Chris Angelico wrote:
> On Thu, Aug 1, 2013 at 7:08 PM, <hambergcfa@gmail.com> wrote:
>
> 1) You receive an email
>
> 2) That email has two URLs in it ("secure hyperlinks" means they begin
>
> https:// ?)
>
> 3) You choose one of them as being "appropriate" - is it always the second?
>
> 4) You download the document at that URL, which requires a password
>
> 5) You then run some sort of alteration on the resulting CSV file.
>
> Please correct me on anything I've misunderstood.
>
> Python can certainly do all of these steps, with the possible
>
> exception of fetching the email. Dividing the problem up into separate
>
> steps will make the solving of it easier.
>
> ChrisA
>
> Thanks a lot ChrisA! You are correct with everything except that the login hyperlink is always the first link and the second one is the link to register.
>
> Okay!
>
> Digression: You seem to be using Google Groups. Please read
>
> http://wiki.python.org/moin/GoogleGroupsPython before posting further,
>
> to avoid antagonizing the list's best responders.)
>
> The first step is to figure out how to retrieve the email. You may
>
> want to tweak your setup to make this easier. The next thing I'd do
>
> would be to port the macro to Python. Everything in between is fairly
>
> easy.
>
> ChrisA
>
> Thanks for the heads up ChrisA! How should I tweak my setup to make it easier to retrieve my email? I hope I'm doing this reply correctly.
> --
> http://mail.python.org/mailman/listinfo/python-list
Reading outlook email, I found this:
http://timgolden.me.uk/python/win32_how_do_i/read-my-outlook-inbox.html
There is lots to find via google with 'reading outlook email with python'
--
Joel Goldstick
http://joelgoldstick.com
[toc] | [prev] | [next] | [standalone]
| From | Skip Montanaro <skip@pobox.com> |
|---|---|
| Date | 2013-08-02 14:25 -0500 |
| Message-ID | <mailman.131.1375471533.1251.python-list@python.org> |
| In reply to | #51820 |
> Reading outlook email, I found this: > > http://timgolden.me.uk/python/win32_how_do_i/read-my-outlook-inbox.html > > There is lots to find via google with 'reading outlook email with python' You might also want to look at the source for the SpamBayes Outlook plugin: https://pypi.python.org/pypi/spambayes Skip
[toc] | [prev] | [next] | [standalone]
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2013-08-02 23:30 +0100 |
| Message-ID | <mailman.133.1375482629.1251.python-list@python.org> |
| In reply to | #51820 |
On Fri, Aug 2, 2013 at 7:18 PM, <hambergcfa@gmail.com> wrote: > How should I tweak my setup to make it easier to retrieve my email? I hope I'm doing this reply correctly. The best way is to use email, not the Google Groups interface. Start here: http://mail.python.org/mailman/listinfo/python-list You can use gmail, and it'll thread the conversations for you. (So will many other clients, but you clearly already have gmail.) The usual convention is to use angle brackets with quoted text, and also to wrap your sent text to a reasonable number of characters (about 80 is common; most clients will do this for you - gmail will as long as you send Plain Text rather than formatted, which is a good idea anyway). ChrisA
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.python
csiph-web