• 大小: 0.10M
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2020-12-14
  • 语言: C#
  • 标签: C#  自动关机  

资源简介

C#编写的自动关机简单Demo

资源截图

代码片段和文件信息

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

namespace WindowsFormsApplication1
{
    public partial class 关机 : Form
    {
        private DateTime end;
        public 关机()
        {
            InitializeComponent();
            yearLabel.Text = DateTime.Now.Year.ToString();
            monthLabel.Text = DateTime.Now.Month.ToString();
            dayLabel.Text = DateTime.Now.Day.ToString();
            hourLabel.Text = DateTime.Now.Hour.ToString();
        }

        private void button1_Click(object sender EventArgs e)
        {
            shutdown();
        }
        public static void shutdown()
        {
           

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

     文件       2196  2018-04-18 18:47  WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.vshost.application

     文件      22984  2018-04-18 18:47  WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.vshost.exe

     文件       3086  2018-04-18 18:47  WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.vshost.exe.manifest

     文件       2198  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\bin\Release\WindowsFormsApplication1.application

     文件      16896  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\bin\Release\WindowsFormsApplication1.exe

     文件       3089  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\bin\Release\WindowsFormsApplication1.exe.manifest

     文件      24064  2018-04-18 18:49  WindowsFormsApplication1\WindowsFormsApplication1\bin\Release\WindowsFormsApplication1.pdb

     文件       2196  2018-04-18 18:49  WindowsFormsApplication1\WindowsFormsApplication1\bin\Release\WindowsFormsApplication1.vshost.application

     文件      22472  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\bin\Release\WindowsFormsApplication1.vshost.exe

     文件       3086  2018-04-18 18:49  WindowsFormsApplication1\WindowsFormsApplication1\bin\Release\WindowsFormsApplication1.vshost.exe.manifest

     文件       3195  2018-04-18 18:48  WindowsFormsApplication1\WindowsFormsApplication1\Form1.cs

     文件       8105  2013-11-19 14:17  WindowsFormsApplication1\WindowsFormsApplication1\Form1.Designer.cs

     文件      13409  2013-11-19 14:17  WindowsFormsApplication1\WindowsFormsApplication1\Form1.resx

     文件       7259  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\Release\DesignTimeResolveAssemblyReferencesInput.cache

     文件       2198  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\Release\WindowsFormsApplication1.application

     文件      16896  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\Release\WindowsFormsApplication1.exe

     文件       3089  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\Release\WindowsFormsApplication1.exe.manifest

     文件        180  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\Release\WindowsFormsApplication1.Properties.Resources.resources

     文件       5344  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\Release\WindowsFormsApplication1.关机.resources

     文件       1177  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\Release\关机程序.csproj.FileListAbsolute.txt

     文件        975  2018-04-18 18:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\Release\关机程序.csproj.GenerateResource.Cache

     文件       2867  2018-04-18 18:47  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Debug\DesignTimeResolveAssemblyReferences.cache

     文件       7258  2018-04-18 18:47  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Debug\DesignTimeResolveAssemblyReferencesInput.cache

     文件        564  2013-11-19 14:18  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Debug\GenerateResource.read.1.tlog

     文件       1152  2013-11-19 14:18  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Debug\GenerateResource.write.1.tlog

     文件       1142  2013-04-07 13:50  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Debug\WindowsFormsApplication1.csproj.FileListAbsolute.txt

     文件       4516  2018-04-18 18:49  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Debug\关机程序.csproj.FileListAbsolute.txt

     文件       7262  2018-04-18 18:49  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Release\DesignTimeResolveAssemblyReferencesInput.cache

     文件        400  2013-04-07 10:36  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Release\GenerateResource.read.1.tlog

     文件        974  2013-04-07 10:36  WindowsFormsApplication1\WindowsFormsApplication1\obj\x86\Release\GenerateResource.write.1.tlog

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

评论

共有 条评论