示例#1
0
            public static bool assertAccessDB()
            {
                try
                {
                    //asserts the file exists
                    if (File.Exists(path + "VDI.accdb"))
                    {
                        result = true;
                        Console.WriteLine("Access file saved as: " + fileName);
                    }
                }
                catch (Exception e)
                {
                    Console.WriteLine("Error " + e.Message);
                }

                try
                {
                    Available.DeleteAllFilesInPath(path);
                }
                catch (Exception e)
                {
                    Console.WriteLine("Error " + e.Message);
                }
                return(result);
            }
示例#2
0
        /// <summary>
        /// searches for all the permited formats and delete those files.
        /// </summary>

        public static bool CheckZip(string zip)
        {
            if (File.Exists(zip))
            {
                Available.DeleteAllFilesInPath(path);
                return(true);
            }
            else
            {
                return(false);
            }
        }
示例#3
0
 public static bool assertWordDoc()
 {
     try
     {
         //asserts the file exists
         if (File.Exists(path + "VDI.docx"))
         {
             result = true;
             Console.WriteLine("Word file saved as: " + filename);
             Available.DeleteAllFilesInPath(path);
         }
     }catch (Exception e)
     {
         Console.WriteLine("file " + filename + " not found");
     }
     return(result);
 }
示例#4
0
 public static bool assertExcel()
 {
     try
     {
         //asserts the file exists
         if (File.Exists(path + "VDI.xlsx"))
         {
             result = true;
             Console.WriteLine("Excel file saved as: " + fileName);
         }
         Available.DeleteAllFilesInPath(path);
     }
     catch (Exception e)
     {
         Console.WriteLine("Excel file " + fileName + " not found");
     }
     return(result);
 }
示例#5
0
            public static bool assertPowerPoint()
            {
                try
                {
                    //asserts the file exists
                    if (File.Exists(path + "VDI.pptx"))
                    {
                        result = true;
                        Console.WriteLine("PowerPoint file saved as: " + fileName);
                    }


                    Available.DeleteAllFilesInPath(path);
                }
                catch (Exception e)
                {
                    Console.WriteLine("Assert PowerPoint Failed: " + fileName + "\n" + e.Message);
                }
                return(result);
            }