引用
using System.Runtime.InteropServices;  //引用 DllImport
宣告
[DllImport("coredll.dll", EntryPoint = "FindWindow")]
private static extern int FindWindow(string lpClassName, string lpWindowName);
[DllImport("coredll.dll", EntryPoint = "ShowWindow", CharSet = CharSet.Auto)]
public static extern int ShowWindow(int hwnd, int nCmdShow);
調用
int _taskbarHandle = FindWindow("HHTaskBar", "");
ShowWindow(_taskbarHandle, 0); //隱藏
ShowWindow(_taskbarHandle, 1); //顯示

arrow
arrow
    全站熱搜

    神風地球喵 發表在 痞客邦 留言(0) 人氣()