P/Invoke.注册表监测

搞c#3周了,还是用起来觉得不顺。自己写不出来新东西,在codeproject上找了个监测注册表的,结果在.net 2.0上跑不起来,结果问问作者,说是2.0和1.0中的有点出入,结果当时没有来得及看到,导致我自己完全pinvoke了一个类。所以贴出来让大家批判一下,老风格:贴代码,很简单,不做说明了。

using System;
using System.Collections.Generic;
using System.Text;
using System.Runtime.InteropServices;
using System.Threading;


namespace hhRegMonitor
{
    
//监测的类型
    public class RegChangeNotifyFilter
    


    
//监测的根
    public class RegRootKey
    


    
public class RegistryMonitor
    

}


测试demo
class Program
    

    
public class testmonitor
    

类结构参考 http://www.codeproject.com/csharp/registrymonitor.asp
posted on 2005-12-20 10:30  flyingleaf  阅读(776)  评论(0编辑  收藏  举报