これは印刷用スクリーン、
using System.Drawing;
using System.Drawing.Imaging;
Bitmap printscreen = new Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height);
Graphics graphics = Graphics.FromImage(printscreen as Image);
graphics.CopyFromScreen(0, 0, 0, 0, printscreen.Size);
printscreen.Save(@"filepath", ImageFormat.Jpeg);
これをコントローラーに入れてみましたが、画面を何も認識しません。
これは取り付けるためのもので、
System.Net.Mail.Attachment attachment;
attachment = new System.Net.Mail.Attachment("you attachment file");
mMailMessage.Attachments.Add(attachment);
このようにファイルパスを追加することはできますか?: new System.Net.Mail.Attachment("filepath");