{          inttimeHour=DateTime.Now.Hour;          if(timeHour==3)            stata=0;          #region更新学生基本信息          if(studentbegintime<=timeHour&&timeHour         {          inttimeHour=DateTime.Now.Hour;          if(timeHour==3)            stata=0;          #region更新学生基本信息          if(studentbegintime<=timeHour&&timeHour
登录
首页 » C# » C#自动更新服务(本地服务安装)

C#自动更新服务(本地服务安装)

于 2015-03-11 发布
0 229
下载积分: 1 下载次数: 0

代码说明:

using System;using System.Collections.Generic;using System.Linq;using System.Text;using Common.WinService;using Common.Log;using System.Threading;using Common.Net;using System.Text.RegularExpressions;namespace Collection.AutoRunner{    //获取学生信息    public class Service_Update_Data : IWindowsService    {        private ILogWriter _logWriter = null;        private const string logCategory = "Services.Info";        private string logInfoSource = "Update_Data";        private const string logErrorCategory = "Services.Error";        private const string logErrorSource = "Update_Data_Error";        private bool BeStop = true;        private System.Timers.Timer timer = null;        public void Start(Common.Log.ILogWriter logWriter, string gameCode)        {            gameCode = gameCode.ToUpper();            logInfoSource = gameCode;            _logWriter = logWriter;            BeStop = false;            StartRequestData();        }        int stata = 0;        private void StartRequestData()        {            try            {                #region 配置                //时间频率                var UpdateStudentSpan = ServiceHelper.GetInterval("UpdateData");                //更新学生开始时间                var studentbegintime = ServiceHelper.GetInterval("StudentBeginTime");                //更新学生结束时间                var studentendtime = ServiceHelper.GetInterval("StudentEndTime");                    //是否更新学生基本信息:true为更新 false为不更新                var IsUpdateStudnet =Convert.ToBoolean(ServiceHelper.GetSystemConfig("IsUpdateStudnet"));                                #endregion                timer = ServiceHelper.ExcuteByTimer(UpdateStudentSpan, () =>                {                    int timeHour = DateTime.Now.Hour;                    if (timeHour == 3)                        stata = 0;                    #region 更新学生基本信息                    if (studentbegintime

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • StaticImage
    vc——使用静态文本控件显示图标和位图StaticImage(vc- Use static text control to display icons and bitmaps StaticImage)
    2011-07-24 20:29:18下载
    积分:1
  • PeerYou远控制软件源代码
    完全实现注册表处理,文件处理。服务端采用多线程服务,能最好的处理SOCKET请求。数据接收、发送函数可以说是现阶段最好的,采用异步重叠操作。可以取得被控机器上的硬件信息,文件信息,注册表以及进行屏幕控制。 代码中的SOCKET重叠I/O的实现也很值得参(complete registry handling, document handling. Server using multithreading services will best address SOCKET request. Data reception, sending function can be said at this stage the best, using asynchronous overlapping operations. Machines can get charged with the hardware information, document information, registry and control for the screen. SOCKET code of overlapping I/O is also the realization worth Participation)
    2005-05-07 13:56:36下载
    积分:1
  • DisWinLynn
    说明:  自己写的一个可以屏蔽系统键的程序,可以屏蔽WIN键,当然你可以修改其他屏蔽键!(玩魔兽时防止按错退出写的一个自己用的辅助工具)(himself in a system can shield key procedures, shielding WIN button, of course, you can modify other shielding keys! (Barry wrong by preventing the withdrawal was made with one of his aids))
    2005-10-08 13:21:56下载
    积分:1
  • tqe
    根据图片格式定义,实现快速读取图的分辨率大小(According to the image format definition, achieve rapid read figure resolution size)
    2017-07-13 00:45:46下载
    积分:1
  • C#联通网络宽带测试 拨号实例源码
    C#拨号实例
    2014-09-25下载
    积分:1
  • EDIDVIEW
    读取注册表中关于显示器edid的记录信息。(Get the EDID information from Reg.)
    2011-12-28 19:45:54下载
    积分:1
  • 1
    说明:  分解质因数的问题,采用c++语言编写,。。。。。(Using C++ algrithem)
    2012-03-30 19:29:51下载
    积分:1
  • CSA算法MATLAB代码
    本代码详细的阐述了CSA算法的编写过程 具体参数参考合成孔径雷达成像-算法与实现
    2019-04-03下载
    积分:1
  • WebBrowser中元素赋值与模拟点击,实现模拟输入表单,并提交表单
    WebBrowser模拟操作功能实现
    2012-12-30下载
    积分:1
  • PE-digital-signature-
    提取PE文件的数字签名,还可以写入数字签名(PE files extracted digital signature, digital signature can also be written)
    2011-05-01 20:45:18下载
    积分:1
  • 696516资源总数
  • 106442会员总数
  • 11今日下载