반응형
public class TaskbarController
{
[DllImport("user32.dll")]
private static extern int FindWindow(string className, string windowText);
{
[DllImport("user32.dll")]
private static extern int FindWindow(string className, string windowText);
[DllImport("user32.dll")]
private static extern int ShowWindow(int hwnd, int command);
private const int SW_HIDE = 0;
private const int SW_SHOW = 1;
private static int _GetTrayHandler()
{
return FindWindow("Shell_TrayWnd", "");
}
public static void ShowTaskbar()
{
ShowWindow(_GetTrayHandler(), SW_SHOW);
}
public static void HideTaskbar()
{
ShowWindow(_GetTrayHandler(), SW_HIDE);
}
#endregion
}
반응형
'프로그래밍 > C#.net' 카테고리의 다른 글
Constructor (0) | 2009.08.24 |
---|---|
클래스 (0) | 2009.08.24 |
바탕화면을 부모로 가지기 (0) | 2009.03.24 |
FormBorder.None 에 간단하게 드래그이벤트 추가 코드 (0) | 2009.03.24 |
WinService구동시 installutil문제 (2) | 2009.02.17 |
댓글