Outlook メッセージのカラーカテゴリを設定
Contents
[
Hide
]
Aspose.Email - Outlook メッセージのカラーカテゴリ設定
Microsoft Outlook はユーザーがメールを区別するためにカラーカテゴリを割り当てることができます。カラーカテゴリはメールの重要度やカテゴリを示します。Aspose.Email は同様の機能を提供します。 FollowUpManager クラスです。このクラスでサポートされている機能は次のとおりです:
- AddCategory() は MapiMessage およびカラーカテゴリ文字列を引数として受け取ります。
- removeCategory() は MapiMessage と、メッセージから削除するカラーカテゴリ文字列を引数として受け取ります。
- clearCategories() はメッセージからすべてのカラーカテゴリを削除するために使用されます。
- getCategories() は特定のメッセージからすべてのカラーカテゴリを取得するために使用されます。
Java
MapiMessage msg = MapiMessage.fromFile(dataDir + "message.msg");
// Add category
FollowUpManager.addCategory(msg, "Purple Category");
// Add another category
FollowUpManager.addCategory(msg, "Red Category");
// Retrieve the list of available categories
IList categories = FollowUpManager.getCategories(msg);
// Remove the specified category
FollowUpManager.removeCategory(msg, "Red Category");
// Clear all categories
//FollowUpManager.clearCategories(msg);
msg.save(dataDir + "AsposeCategories.msg");
実行コードをダウンロード
サンプルコードをダウンロード
詳細については、こちらをご覧ください Outlook メッセージ(MSG)ファイルのカラーカテゴリ設定.