Juvigy Posted June 19, 2013 Posted June 19, 2013 I have a PST which is an archive from an General Mailbox. Inside there are different types of mails in different languages: Some are HTML other TEXT , some in English other in French and German. I would like to be able to programatically tell in which language is the mail. Any idea how this can be done? PS. I am fairly familiar with the outlook UDFs and MSDN Outlook object reference.
Myicq Posted June 19, 2013 Posted June 19, 2013 As I see it, not really a question related to AutoIT specifically but for programming in general. And a hard one too, as "language" is a soft parameter which is hard to analyze. This page has some suggestions. One of them being detectlanguage.com - the API seems to be free to use. For no API use, perhaps you have distinct words you can search for ? Not much of a solution, just some general pointers. Hope they're helpful to you. I am just a hobby programmer, and nothing great to publish right now.
Juvigy Posted June 19, 2013 Author Posted June 19, 2013 The problem is i will need 20 000 detections. The free version is only 5k per day.
water Posted June 19, 2013 Posted June 19, 2013 Give function _OL_MailHeaderget a try. In the example I have run here I get ... "Accept-Language: de-DE, de-AT, en-US" "Content-language: de-DE" ... for a mail written in german. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
Juvigy Posted June 19, 2013 Author Posted June 19, 2013 Doesnt work for most of my mails - If there is some english - for example in the signiture it says it is English and not Deutch.
water Posted June 19, 2013 Posted June 19, 2013 Looks like that is the only automated information Outlook provides. But how would you determine the language of a mixed mail? My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki
Juvigy Posted June 20, 2013 Author Posted June 20, 2013 I am thinking of getting the mail body only and checking 10% of the words against a dictionary or something. I am still thinking about it.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now