C#StudentMIS
时间: 2023-11-22 20:50:37 浏览: 33
C# StudentMIS是一个学生信息管理系统,使用C#编写。以下是一个简单的示例,演示如何创建目录并复制文件:
```csharp
using System;
using System.IO;
namespace StudentMIS
{
class Program
{
static void Main(string[] args)
{
// 创建目录
string sPath = @"E:\StudentMIS\list";
Directory.CreateDirectory(sPath);
// 复制文件
string sFilePath = @"E:\StudentMIS\list\1班学生名单.log";
string sNewFilePath = @"D:\1班学生名单.log";
FileInfo file = new FileInfo(sFilePath);
file.CopyTo(sNewFilePath, true);
Console.WriteLine("操作完成!");
}
}
}
```