Outlook changing programatically attached csv file to xlsx when sending RRS feed

  • Question

  • we have a function in AutoCAD that attaches some data (xlsx, csv, and pdf) to an email message that is sent to various people in the company. Up until just recently, it's worked just fine. but a few people have started noticing that it's changing the csv file to xlsx when it sends. when the message pops up before sending, the csv file is there and everything is good, but as soon as it hits the outbox, it's changed to xlsx. I noticed there was a number of updates to office recently. all of these people are on a forced automatic update. I am not on automatic update, and i'm not having the issue. I don't really want to go update by update uninstalling and checking, because that would take forever since i'll likely have to close and re-open autocad for each test, probably have to reboot 40 times, a nightmare you can imagine. if anybody knows the update that's causeing this, it would save me a ton of time. or if you know how to resolve the issue, even better.

    what I've tried is to force the Mime Content Type using:

    Public Const PR_ATTACH_MIME_TAG = ""
        Public Sub SetMime(Attachment As Microsoft.Office.Interop.Outlook.Attachment)
            Attachment.PropertyAccessor.SetProperty(PR_ATTACH_MIME_TAG, Mime.GetMime(Attachment.FileName).MediaType)
        End Sub

    The GetMime just looks up the right mime type, which for csv, i'm returning "text/csv"

    any help would be greatly appreciated, thanks!

    Tuesday, September 15, 2015 6:56 PM

All replies

  • What Outlook version are you talking about? When and where do you run the code?
    Tuesday, September 15, 2015 7:10 PM
  • Hi timbot,

    What’s the result of they send the email manually?



    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Wednesday, September 16, 2015 8:47 AM