[System.Runtime.InteropServices.DllImport("user32.dll", EntryPoint="ShowCursor")] internal extern static bool ShowCursor ( bool bShow ) ;
// 隐藏 显示 鼠标 public static void Hide()
{
ShowCursor( false ) ;
}
public static void Show()
{
ShowCursor( true ) ;
}
// 隐藏 显示 鼠标 public static void Hide()
{
ShowCursor( false ) ;
}
public static void Show()
{
ShowCursor( true ) ;
}
[DllImport("user32.dll", EntryPoint="ShowCursor",CharSet=CharSet.Auto)]
public extern static void ShowCursor(int status);
调用ShowCursor(0)或ShowCursor(1)来设置.
与上面的一样.只是调用个api.