Hello,
I hope you all enjoyed the holidays and wish you the best of luck in the upcoming new year
Got 2 questions:
Under PersonalStorage.ItemMoved event, how can I get the message subject using e.ItemProperties?
Never used Mapi ItemProperties so would be nice to know
There’s no such thing like PersonalStorage.StoragePreProcess event so how can I get some info on storage begin process?
Mostly I need to know the name of storage (e.FileName)
My usage:
PersonalStorage.MergeWith(MySourceFiles.ToArray)
MySourceFiles is defined as List(Of String)
Thanks
@australian.dev.nerds
We suggest you please check the code example of PersonalStorage.ItemMoved from here:
using System;
using System.IO;
using Aspose.Email.Storage.Pst;
/*
This project uses Automatic Package Restore feature of NuGet to resolve Aspose.Email for .NET API reference
when the project is build. Please check https://Docs.nuget.org/consume/nuget-faq for more information.
If you do not wish to use NuGet, you can manually download Aspose.Email for .NET API from https://www.nuget.org/packages/Aspose.Email/,
install it and then add its reference to this project. For any issues, questions or suggestions
please feel free to contact us using https://forum.aspose.com/c/email
*/
namespace Aspose.Email.Examples.CSharp.Email.Outlook
{
class SplitSinglePSTInToMultiplePST
{
public int totalAdded;
public static int messageCount;
public static string currentFolder;
public static void Run()
This file has been truncated. show original
You can get the message subject using following code snippet.
static void PstMerge_OnItemMoved(object sender, ItemMovedEventArgs e)
{
if (e.IsMessage)
{
Console.WriteLine("Message : " + e.ItemProperties[MapiPropertyTag.PR_SUBJECT_W]);
}
}
To work with MAPI properties, please read the following article:
Working with MAPI Properties
Could you please share some more detail about this requirement?
1 Like
Hi, thanks for the info, in my usage:
PersonalStorage.MergeWith(MySourceFiles.ToArray)
StorageProcessed occurs after each source storage file is processed.
Anyway to get it before source storage file is going to process?
Best
@australian.dev.nerds
A ticket EMAILNET-40902 has been logged for your requirement in our issue tracking system. We will inform you once there is an update available on it.