string path = project.Variables["path"].Value; // переменная пути к файлу
long fileBytes = long.Parse(project.Variables["fileBytes"].Value); // переменная размера файла в байтах
FileInfo file = new FileInfo(path);
if (file.Length < fileBytes)
file.Delete();