Esempio n. 1
0
        public bool SaveToFolder(string folderPath)
        {
            bool success = false;

            if (Directory.Exists(folderPath))
            {
                _theAttachment.Save(Path.Combine(folderPath, FileNameTrue));
                success = true;
            }

            return(success);
        }
        public void CopyToEmailOut(MimeData theAttachment, AowGame theGame)
        {
            if (theAttachment != null && theGame != null)
            {
                string fileName = theAttachment.FileName;

                if (!string.IsNullOrEmpty(fileName))
                {
                    string destPath = Path.Combine(theGame.EmailOut.FullName, fileName);

                    if (File.Exists(destPath))
                    {
                        File.Delete(destPath);
                    }

                    theAttachment.Save(destPath);
                }
            }
        }