zoukankan      html  css  js  c++  java
  • ShellExecute

         [DllImport("shell32.dll")]
            public extern static IntPtr ShellExecute(IntPtr hwnd,
                                                     string lpOperation,
                                                     string lpFile,
                                                     string lpParameters,
                                                     string lpDirectory,
                                                     int nShowCmd
                                                    );
            public enum ShowWindowCommands : int
            {

                SW_HIDE = 0,
                SW_SHOWNORMAL = 1,
                SW_NORMAL = 1,
                SW_SHOWMINIMIZED = 2,
                SW_SHOWMAXIMIZED = 3,
                SW_MAXIMIZE = 3,
                SW_SHOWNOACTIVATE = 4,
                SW_SHOW = 5,
                SW_MINIMIZE = 6,
                SW_SHOWMINNOACTIVE = 7,
                SW_SHOWNA = 8,
                SW_RESTORE = 9,
                SW_SHOWDEFAULT = 10,
                SW_MAX = 10
            }
    一下则是为实现我上述两个功能的函数调用:
    1、访问http://blog.csdn.net/wellwelcome
    ShellExecute(this.Handle, "open", "http://blog.csdn.net/wellwelcome", null, null, (int)ShowWindowCommands.SW_SHOW);
    2、email wuzhongxin@263.net
    ShellExecute(this.Handle, "open", "mailto:wuzhongxin@263.net", null, null, (int)ShowWindowCommands.SW_SHOW);

  • 相关阅读:
    unity free asset
    Unity3d Serialize问题
    野蛮能带来繁荣是怎么回事?
    如何给unity3d工程加入依赖的android工程
    unity3d 导入google play services插件工程
    NGUI中UILabel使用url标签的一个bug
    数据结构
    git命令
    面试算法经典问题
    Http Client 源码分析
  • 原文地址:https://www.cnblogs.com/xiaogelove/p/3035901.html
Copyright © 2011-2022 走看看