摘要:[STAThread] static void Main() { Process instance = RunningInstance(); if (instance == null) { Application.Run(new mainFrm()); } else { //MessageBox.Show("此程序已经启动!"); HandleR...
阅读全文
文章分类 - c#
摘要:1.通过执行命令,会有cmd窗口一闪而过: public void Get_Share(string remotepath, string localpath, string username, string password) { Process.Start("net"," use "+localpath+" "+remotepath+" "+password+" /user:"+use...
阅读全文
摘要:因为业务需要,需要给公司部分终端进行登记,以保证授权终端能够登录业务系统,最好的方法就是记录下每台终端的MAC地址来进行验证是否有授权。 下面是采用调用API的方式获取指定IP的终端的MAC地址: [DllImport("Iphlpapi.dll")] public static extern int SendARP(Int32 dest, Int32 host, re...
阅读全文

浙公网安备 33010602011771号