• 大小: 0.04M
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2021-02-25
  • 语言: C#
  • 标签: NUMLOCK键  caploack键  

资源简介


资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace IsNumAndCapsLock
{
    public partial class Frm_Main : Form
    {
        public Frm_Main()
        {
            InitializeComponent();
        }
        //重写API函数
        [System.Runtime.InteropServices.DllImport(“user32“ EntryPoint = “GetKeyState“)]
        public static extern int GetKeyState(int intkey);

        private void button1_Click(object sender EventArgs e)
        {
            string strChenk = “判断NumLock键和CapsLock键是否锁定:\n“;
            int intNumLock = GetKeyState(144);//判断NumLock键
            if (intNumLock == 0)
            {
                strChenk += “NumLock键未锁定\n“;
            }
            else
            {
                strChenk += “NumLock键已锁定\n“;
            }
            int intCapsLock = GetKeyState(20);//判断CapsLock键
            if (intCapsLock =

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       8704  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\bin\Debug\IsNumAndCapsLock.exe

     文件      30208  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\bin\Debug\IsNumAndCapsLock.pdb

     文件      14328  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\bin\Debug\IsNumAndCapsLock.vshost.exe

     文件        490  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\bin\Debug\IsNumAndCapsLock.vshost.exe.manifest

     文件       1356  2016-12-21 17:48  IsNumAndCapsLock\IsNumAndCapsLock\Frm_Main.cs

     文件       2199  2016-12-21 17:48  IsNumAndCapsLock\IsNumAndCapsLock\Frm_Main.designer.cs

     文件       5814  2016-12-21 17:48  IsNumAndCapsLock\IsNumAndCapsLock\Frm_Main.resx

     文件       4001  2016-12-21 17:48  IsNumAndCapsLock\IsNumAndCapsLock\IsNumAndCapsLock.csproj

     文件       7050  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache

     文件       2181  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\IsNumAndCapsLock.csproj.FileListAbsolute.txt

     文件        850  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\IsNumAndCapsLock.csproj.GenerateResource.Cache

     文件       8704  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\IsNumAndCapsLock.exe

     文件        180  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\IsNumAndCapsLock.Frm_Main.resources

     文件      30208  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\IsNumAndCapsLock.pdb

     文件        180  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\IsNumAndCapsLock.Properties.Resources.resources

     文件       4608  2016-12-22 04:17  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\TempPE\Properties.Resources.Designer.cs.dll

     文件        500  2016-12-21 17:48  IsNumAndCapsLock\IsNumAndCapsLock\Program.cs

     文件       1364  2016-12-21 21:16  IsNumAndCapsLock\IsNumAndCapsLock\Properties\AssemblyInfo.cs

     文件       2872  2016-12-21 21:16  IsNumAndCapsLock\IsNumAndCapsLock\Properties\Resources.Designer.cs

     文件       5612  2016-12-21 21:16  IsNumAndCapsLock\IsNumAndCapsLock\Properties\Resources.resx

     文件       1116  2016-12-21 21:16  IsNumAndCapsLock\IsNumAndCapsLock\Properties\Settings.Designer.cs

     文件        249  2016-12-21 21:16  IsNumAndCapsLock\IsNumAndCapsLock\Properties\Settings.settings

     文件        938  2016-12-21 16:09  IsNumAndCapsLock\IsNumAndCapsLock.sln

     目录          0  2016-12-22 04:17  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\Refactor

     目录          0  2016-12-22 04:17  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug\TempPE

     目录          0  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\bin\Debug

     目录          0  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\bin\Release

     目录          0  2016-12-22 04:17  IsNumAndCapsLock\IsNumAndCapsLock\obj\Debug

     目录          0  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\bin

     目录          0  2016-12-22 03:30  IsNumAndCapsLock\IsNumAndCapsLock\obj

............此处省略6个文件信息

评论

共有 条评论

相关资源