Jump to content

Recommended Posts

Posted (edited)

Hey

well I posted earlier asking how to open a file (.xls) that is an attachment in an email(Im using Outlook 2003) but so far noone has responded and I cant find anything on the internet on how to do this. So does anybody know of a way to save the .xls file attachment? Again I can count the number of attachments and retrieve the file names, but I dont know how to do anything else.

Edited by hutteto
Posted

A bit more information about email-application please.

Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs, and the Universe
trying to produce bigger and better idiots.
So far, the Universe is winning.

Posted

You need to know(get) URLs of attachments, and then InetGet()

:(

What do you mean? Are you saying that instead of attachments, have links to the file and then get to the file by way of the link?
Posted (edited)

Yes, and I don't see another way to do that..

Well I've already been there and done that from another report I do. Here's how I accomplish opening the link:

;Reteives the URL from the email
    $ACIR_LINK_Extract = _Stringbetween($mBody, "http:",">")
    $ACIR_LINK_Complete = "http:" & $ACIR_LINK_Extract[0]
    ;Msgbox(0,"Actual Link: ", $ACIR_LINK_Complete)
    
    ;Opens the URL in a new IE window
    $oIE1 = _IECreate($ACIR_LINK_Complete)

Its a little irritating that you cant open an attachment. That seems like it would be a popular/important task. I see in Outlook there is an attachments option in the file menu. Anyway to save the attachments?

Edited by hutteto
Posted (edited)

A bit more information about email-application please.

funkey, sorry about that(Outlook 2003). Here is my 1st post with all the detail.

http://www.autoitscript.com/forum/index.php?showtopic=112122

Edited by hutteto
Posted (edited)

$ACIR_LINK_Extract = _Stringbetween($mBody, "http:",">")
    $ACIR_LINK_Complete = "http:" & $ACIR_LINK_Extract[0]
    ;Msgbox(0,"Actual Link: ", $ACIR_LINK_Complete)

    ;Opens the URL in a new IE window
    ;$oIE1 = _IECreate($ACIR_LINK_Complete)
    InetGet($ACIR_LINK_Complete, @DocumentsCommonDir & "\file"); Download attachment to documents dir

Edited by GodlessSinner

_____________________________________________________________________________

Posted

There is a saveasfile method in Outlook:

http://msdn.microsoft.com/en-us/library/...terop.outlook.attachment.saveasfile.aspx

You can use it to save attachments.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...