コメント
コメントの投稿
※名前とタイトルが入力されていないコメントでは他のコメントとの区別ができません。
入力されていないコメントには返信しませんのであらかじめご了承くださいませ。
var content = new UNMutableNotificationContent();
・・・
/*リソース画像の設定*/
//ファイル名と拡張子を指定する
var localURL = "file:///" + NSBundle.MainBundle.PathForResource("Icon", "png");
NSUrl url = NSUrl.FromString(localURL);
var attachmentID = "image";
var options = new UNNotificationAttachmentOptions();
NSError error;
var attachment = UNNotificationAttachment.FromIdentifier(attachmentID, url, options, out error);
//UNMutableNotificationContentのインスタンスに画像設定を追加します。
content.Attachments = new UNNotificationAttachment[] { attachment };
※名前とタイトルが入力されていないコメントでは他のコメントとの区別ができません。
入力されていないコメントには返信しませんのであらかじめご了承くださいませ。