Quantcast
Channel: Aspose.Email Product Family
Viewing all 1367 articles
Browse latest View live

Aspose.Email and System.Threading.ThreadAbortException

$
0
0
My team just upgraded from Aspose.Email v6.6.0 to 17.1.0. We have a bunch of NUnit3 -based integration tests that still pass with the new version; however, there are a massive number of stacktraces similar to the one at the bottom. Every time the tests are run (local or CI), you end up with a huge number of these statements. The debugger output happens whenever you construct the ImpacClient object. No more, no less. The tests in question do NOT involve threading of any kind (Thread, async/await, Task, etc.)

Beyond being annoying, the fact we had never seen this before makes me nervous about using this version. I can tell you that all of our tests are passing. I'm guessing these are first-chance exceptions being reported by the debugger.

Regards,
Scott

System.Threading.ThreadAbortException: Thread was being aborted.
   at #=qbyJod5_mT1wI8odS5bTD_jirvn$tMmm1qLMH4Smgq$BCkSwEl3ym5utXyDasrnOU.#=qeorXweed8ztWSL5k6rfhdQ==()
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()
   at #=qbyJod5_mT1wI8odS5bTD_jirvn$tMmm1qLMH4Smgq$BCkSwEl3ym5utXyDasrnOU.#=qeorXweed8ztWSL5k6rfhdQ==()
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()

Aspose Crashes after memory leak on certain emails

$
0
0
Hi, we use Aspose Email and Aspose Word to convert emails to pdfs. We found certain emails cause a memory leak, locks the thread, freezes our application and eventually allocates all the memory on the server.

Emails attached.

Aspose.Email.Mail.MailMessage mailMsg = Aspose.Email.Mail.MailMessage.Load(email, new Aspose.Email.Mail.MhtmlLoadOptions { PrefferedTextEncoding = Encoding.UTF8 });
using (var ms = new MemoryStream())            {                try                {                    var mailFormatter = new Aspose.Email.Mail.MhtMessageFormatter();                    const Aspose.Email.Mail.MhtFormatOptions mhtFormatOptions = Aspose.Email.Mail.MhtFormatOptions.HideExtraPrintHeader | Aspose.Email.Mail.MhtFormatOptions.WriteCompleteEmailAddress;                    mailFormatter.Format(mailMsg, mhtFormatOptions);                    mailMsg.Save(ms);                }                catch(SystemException ex)                {                    Logging.Error("Could not convert email", ex);                    throw ex;                }
//*********** It fails on this line *******************//
               Aspose.Words.Document document = new Aspose.Words.Document(ms, new Aspose.Words.LoadOptions {  LoadFormat = Aspose.Words.LoadFormat.Mhtml });
....

Unreadable sendername after converting .msg to eml

$
0
0

Attached to this support question, you will find a rar containing a sample.msg file. When I try to convert this .msg file to it's .eml equivalent,I get special character issues on the sender name (header). How can this issue be solved ?

At the moment this is how i do the conversion according to the API:


   MailMessage msg = MailMessage.Load(pathofMsg, MailMessageLoadOptions.DefaultMsg);
   msg.Save(pathtoEml, SaveOptions.DefaultEml);

I am using: 4.0 Aspose.Email for .NET   

Please should you need further information, don't hesitate  to contact me.


Problem processing msg-File sent via Outlook

$
0
0
Hi, 

we have a problem processing a msg-File which was sent via Outlook.

Steps to reproduce:
1. be a sender with a vowel in your name, create a new E-Mail in Outlook and sent it.
2. save the mail from Sent-Folder to your file system e.g. via Drag&Drop
3. read the msg via aspose-email and save it as an eml
4. open the eml in outlook
=> the sender is displayed defect, see attached screenshot defect.jpg

The Problem is, that the FROM isn´t complete in the eml. 
It is:  From: =?iso-8859-1?Q?Dominik_M=E4hl?=
To get it displayed correctly, it has to be: From: =?iso-8859-1?Q?Dominik_M=E4hl?= <email.adress@domain.de>


NSF to MSG Conversion

$
0
0
Hello,
We are craeting MSG Files from NSF database, So at the time of creating MSG every part of the email is working fine except the date. and also the MSG which is created is opening in editable mode.

// Create an instance of the Aspose.Email.MailMessage class
                       MailMessage msg = new MailMessage();
                       // Set recipients information
                        msg.To = doc.GetItemValue("sendto")[0];
                        msg.From = doc.GetItemValue("from")[0];
                        msg.Date = doc.GetItemValue("PostedDate")[0];

                        // Set the subject
                       
                        msg.Subject = doc.GetItemValue("subject")[0];
                   
                        // Set HTML body
                        msg.HtmlBody = nMime.ContentAsText.ToString();
                   
                          msg.Save(global_var.msg_eml_path + sba.ToString() + @"\" + i + ".msg",    SaveOptions.DefaultMsgUnicode);
                    
Thanks & regards
Mantu Malakar         
                

Sending Task

$
0
0
Hi

In our process,we assign tasks to our users using MS Outlook. As we are replacing Outlook with your API, we want to know if this will be possible with this API?

POP3: using logged in credentials

$
0
0
Hi,

We have setup where our users are registered to our domain server in the same network. Is there a way we can use the Pop3 client with logged in user credentials?

Send content of document to body of the mail

$
0
0
Hi,

When i click button, document will be Generated and saved in particular place....
After i want to send to mail only content to the body..
How to Send content of document to body of the mail.....?
Please tell me the solution..



Thank you
NARENDRAN

Aspose.Email.Mail.MailMessage delivers wrong BodyType

$
0
0
Hi,

With our application we are archiving emails via IMAP using Aspose.Email (17.1.0.0).

If an email is formatted in RTF, I get as BodyType "PlainText". Is this an error or does Aspose internally convert the body?

CurrentMessage = Client.FetchMessage(this.CurrentItem.UniqueId);
Aspose.Email.Outlook.BodyContentType bodyType = CurrentMessage.BodyType;

Is there another way to find out the body type of the original email?

Best Regards

Apostrophe in mail subject cause an error

$
0
0
Hi, 
I use version 16.10.0.0
I have created MailQuery object with 

string pSubject = "12345'";
ExchangeQueryBuilder qb = new ExchangeQueryBuilder();
qb.Subject.Contains(pSubject);
MailQuery mailQ = qb.GetQuery();

Please mention the apostrophe in subject;

now I try to use method to list messages.
IEWSClient.ListMessages(folderUri, maxResult, mailQ);

method call fails on error:
System.Web.Services.Protocols.SoapException: The request failed schema validation: The element 'Restriction' in namespace 'http://schemas.microsoft.com/exchange/services/2006/messages' has incomplete content. List of possible elements expected: 'SearchExpression, Exists, Excludes, IsEqualTo, IsNotEqualTo, IsGreaterThan, IsGreaterThanOrEqualTo, IsLessThan, IsLessThanOrEqualTo, Contains, Not, And, Or' in namespace 'http://schemas.microsoft.com/exchange/services/2006/types'.
   at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
   at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
   at Aspose.Email.Exchange.Schema.Exchange_2013.ExchangeServiceBinding.FindItem(FindItemType FindItem1)
at #=qFBZJNJeTrY4DOlsawgw1lNTee5c5eC2B3Vr0KGfVAHnkLfRDAWy6A3PKvu8enu8D.#=qGaV7HzMnlvWwqTc3c2GIFa8iZ$QarTsw_PLYsmSxniM=(ExchangeMessagePageInf.....

I have tried to escape apostrophe character and use 
string pSubject = "12345\'";
but have same result

If I use my code without apostrophe in query - all works fine

please advise solution.
Thanks a lot

Email Tracking C# - Office 365 Exchange server

$
0
0
Dear Team,

We have purchased ASPOSE Email Product. We have below requirement. Can you please share the code and help us out.

We have one common Email Id configured on Office 365 Exchange server. This common ID will be always in CC and we need to track the first and last email thread (Turn around time) for each email.

For E.g:
 Common Email ID : Common@test.com
 Requester Email Id : Request@test.com
 Replies Email Id : Replies@test.com

Requester sends email to Replies email ID and keeps Common Email Id in CC. 
Replies Responds email by keeping common email id in CC.

We need to track turn around time between requester email id & Replies email ID.

Thanks in advance.

how to remove the body content from outlook mail

$
0
0
Hi sir,


            I have one mail, in this mail we have two attachment and message content, for now i want to remove the message content and save only attachment  for further process. pls help me asap. 

Exception of type 'System.OutOfMemoryException' was thrown.

$
0
0
Hi Support,

I am getting error while sending email without attachment. I am using Aspose.Email.dll, v6.9.0.0.  Below is the exception :

Inner exception: "Exception of type 'System.OutOfMemoryException' was thrown."

Stack Trace:
"   at Aspose.Email.Mail.SmtpClient.#=qXpJ35R2Kgz2MYmAGI$rjDA==(IConnection #=qDcF0lfo79WbpwdX1lX3y5w==, IEnumerable #=qPnntbmwKRLjjz1AteckEVQ==, EventHandler`1 #=qnVW_C0EsjJEndxMvtVDIh8ytS7zRWeDnHnShRAZbIgc=)
   at Aspose.Email.Mail.SmtpClient.Send(MailMessage message)"

I am sending email in iteration and after 100 or 200 items, smtpClient.Send(message); method throw out of memory exception.

Note:
1. Exception only came when memory cross 220 mb.
2. Object of Aspose.Email.Mail.SmtpClient class never release its memory.

Please suggest me what went wrong.

How to get today's schedule for a particular user using EWS

$
0
0
What is the right way to get the calendar information for a single email address using EWS? I found ListAppointments() but that seems to get the entire directory. I would like to just find a single person with a datetime range to see what they have going on today.

Thanks,
Josh

Merge Feature

$
0
0
After testing the fix in EMAILNET-38563, it looks like the merge features has an issue.  After the merge Folders in Inbox folder are lost.

Below is the original ticket with the test data:

https://www.aspose.com/community/forums/thread/812955/counts-of-on-merge-feature.aspx


thanks


Get Imap mailbox size

$
0
0
Hello,
I would need to recover the mailbox dimension of an Imap mailbox.
When I use the Pop3Client object I can use the GetMailboxSize function, but with the ImapClient object I can't find any methods that return this value.

Is it possible to retrieve this value in some way?

Thanks.

save all vcf file into single one

$
0
0
hi
sir
we are having a issue of creating vcf file for contacts. we are creating single contact vcf using this code
MapiContact contact = new MapiContact();
                contact.NameInfo = new MapiContactNamePropertySet(firstname, middlename, Lastname);
                contact.PersonalInfo.Gender = MapiContactGender.Male;
                contact.ProfessionalInfo = new MapiContactProfessionalPropertySet(company_name, job_title);
                contact.PhysicalAddresses.WorkAddress.Address = businessAddress + businessCity + businessState;
                contact.Telephones.BusinessTelephoneNumber = mobilePhone;
                contact.Telephones.HomeTelephoneNumber = homePhone;
                contact.Save(outpath +".vcf", ContactSaveFormat.VCard);
this is the code.
but we need single vcf file for more than 1000 contacts.
thankz and regards
Mantu Malakar

Missing LinkedResources Error - Only The Last One Is Sent

$
0
0
Hi Team,

I've picked up an issue with the Email API. I'm wondering whether I'm missing something or whether this is a bug. I'm using the latest version of the API, V16.12.0 which we recently purchased.

Here is the scenario:
When I send an HTML email, it only ever attaches the latest image that I add to my LinkedResources list. See my code below. For example, when I add the Header
and the Footer, I only see the Footer in the received email. When I add the Header,
the Footer and the Trailer, I only see the Trailer in the received email.

But, in all cases, when I save the email to disk, all the images are in the email. So please don't
save it because that is not the scenario. This only happens when you directly Send the MailMessage using SmtpClient without saving the message first.

Please let me know if you're able to reproduce this behaviour or if I'm missing some
configuration setting. I've also attached our HTML for your to see.

Thanks.



public void sendHtmlEmailWithAspose(String recip, String subject, String htmlContent) {
try {
License license = new License();
license.setLicense("/opt/aspose_total_java_v16.lic");

MailMessage msg = new MailMessage();

msg.setFrom(new MailAddress("noreply@company.co.za", "Display Name"));
msg.getTo().add(recip);
msg.setSubject(subject);
msg.setHtmlBody(htmlContent);

LinkedResource headerResource = new LinkedResource("/opt/email_header.png", MediaTypeNames.Image.PNG);
headerResource.setContentId("header_image_cid");
msg.getLinkedResources().addItem(headerResource);

LinkedResource footerResource = new LinkedResource("/opt/email_footer.png", MediaTypeNames.Image.PNG);
footerResource.setContentId("footer_image_cid");
msg.getLinkedResources().addItem(footerResource);

LinkedResource trailerResource = new LinkedResource("/opt/email_header.png", MediaTypeNames.Image.PNG);
trailerResource.setContentId("trailer_image_cid");
msg.getLinkedResources().addItem(trailerResource);

SmtpClient client = new SmtpClient();

client.setHost(serverName);
client.setPort(portNumber);
client.setSecurityOptions(SecurityOptions.None);

client.send(msg);
} catch (Exception e) {
System.out.println("Unable to send Aspose Email: " + e.getMessage());
}
}

Wrong SendDate in the sent emails added from EML to PST

$
0
0
Hello,


First of all, though right now I'm only evaluating your product (ASPOSE.EMAIL) for a future product which I really hope that it will turn into a final project, I'm having a small issue in putting back an EML message saved to disk to a PST file. My scenario works in 99% of the cases and your product is great - it does what is supposed to do in only few lines of code - so 99,99% your library it will be my choice.

The issue is that I'm having some messages (only from the sent items folder) that when are being put back into the PST, they are missing some properties (sending date and sender name) - is not your fault - it seems that is somehow related with the sender client application - doesn't matter. What it matters is that I'm having these missing pieces into a databases and when I'm putting back the EML into PST, if something is missing I'm able to get the required info - so far so good.

If I'm having the sender info missing, I'm using a piece of code found on this forum and it works great but when I'm trying to put the sending date back to the message I'm having some issues.

Even if I'm setting only the MapiPropertyTag.PR_CLIENT_SUBMIT_TIME or also MapiPropertyTag.PR_DELIVER_TIME, the Outlook displays in the list of messages the time when that message has been put back into the PST, BUT (there is a very big BUT) - on the right pane - the details pane - I'm seeing the correct Date that I set in my code. Please, can you tell me what other properties I have to set in order to have also the date displayed in the messages' list correct?

The code that I'm using for setting a date is the following:

public static void SetDatePropertyValue(this MapiMessage message, long mapiTag, DateTime dateTimeValue)
        {
            MapiProperty propertyToSet = new MapiProperty(mapiTag, ConvertDateTimeToMailDateTime(dateTimeValue));
            message.SetProperty(propertyToSet);
        }

ImapClient AutoCommit

$
0
0
Isn't the AutoCommit related to server side attributes? How does it work actually?
Viewing all 1367 articles
Browse latest View live