using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Runtime.InteropServices;
using System.IO;
using System.Threading;
namespace pctoce
{
public partial class Form1 : Form
{
// 声明要引用的API
[DllImport("rapi.dll")]private static extern uint CeRapiUninit();
[DllImport("rapi.dll")]private static extern uint CeRapiInitEx(ref RAPIINIT pRapiInit);
[DllImport("rapi.dll", CharSet=CharSet.Unicode)] internal static extern int CeDeleteFile(string FileName);
[DllImport("rapi.dll", CharSet=CharSet.Unicode)] internal static extern int CeCloseHandle(IntPtr hObject);
[DllImport("rapi.dll", CharSet=CharSet.Unicode)] internal static extern int CeWriteFile(IntPtr hFile, byte[] lpBuffer, int nNumberOfbytesToWrite, ref int lpNumberOfbytesWritten, int lpOverlapped);
[DllImport("rapi.dll", CharSet=CharSet.Unicode, SetLastError=true)]internal static extern IntPtr CeCreateFile(string lpFileName, uint dwDesiredAccess,int dwShareMode,int lpSecurityAttributes,int dwCreationDisposition,int dwFlagsAndAttributes,int hTemplateFile);
[DllImport("rapi.dll", CharSet=CharSet.Unicode)] public static extern int CeFindFirstFile(string lpFileName,ref CE_FIND_DATA lpFindFileData);
[DllImport("rapi.dll", CharSet=CharSet.Unicode)] internal static extern int CeReadFile(int hFile,byte[] lpBuffer,int lpOverlapped,out int laji,int gouride);
[DllImport("rapi.dll", CharSet=CharSet.Unicode)] internal static extern int CeGetFileSize(int hFile, int lpOverlapped);
public struct CE_FIND_DATA
{
public int dwFileAttributes