91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 248KB
    文件類型: .rar
    金幣: 2
    下載: 0 次
    發布日期: 2021-06-12
  • 語言: 其他
  • 標簽: 定時更新??

資源簡介

定時讀取excel更新到數據庫,用2003的excel

資源截圖

代碼片段和文件信息

using?System;
using?System.Collections.Generic;
using?System.Text;
using?System.Data.SqlClient;
using?System.Data;
using?System.Windows.Forms;

namespace?update_material_shortage
{
????class?database
????{//?連接數據源
????????private?SqlConnection?con;

????????///?
????????///?打開數據庫連接.
????????///?

????????public?void?Open()
????????{
????????????//?打開數據庫連接
????????????if?(con?==?null)
????????????{
????????????????con?=?new?SqlConnection(“server=192.168.0.111;uid=sa;pwd=hentech;database=oa;“);

????????????}
????????????if?(con.State?==?ConnectionState.Closed)
????????????{
????????????????try
????????????????{
????????????????????///打開數據庫連接
????????????????????con.Open();
????????????????}
????????????????catch?(Exception?ex)
????????????????{
????????????????????MessageBox.Show(ex.Message);
????????????????}
????????????????finally
????????????????{
????????????????????///關閉已經打開的數據庫連接
????????????????}
????????????}
????????}

????????///?
????????///?關閉數據庫連接
????????///?

????????public?void?Close()
????????{
????????????///判斷連接是否已經創建
????????????if?(con?!=?null)
????????????{
????????????????///判斷連接的狀態是否打開
????????????????if?(con.State?==?ConnectionState.Open)
????????????????{
????????????????????con.Close();
????????????????}
????????????}
????????}
????????///?
????????///?釋放資源
????????///?

????????public?void?Dispose()
????????{
????????????//?確認連接是否已經關閉
????????????if?(con?!=?null)
????????????{
????????????????con.Dispose();
????????????????con?=?null;
????????????}
????????}
????????///?
????????///?執行存儲過程,無返回值,add?by?hins?2013.07.09
????????///?

????????///?sql語句

????????public?void?RunSql(string?strsql)
????????{
????????????Open();

????????????SqlCommand?cmd?=?new?SqlCommand(strsql?con);
????????????cmd.CommandType?=?CommandType.Text;
????????????try
????????????{
????????????????cmd.ExecuteNonQuery();
????????????}
????????????catch?(Exception?ex)

????????????{?
????????????????throw?new?Exception(ex.Message);
????????????}
????????????Close();

????????}
????}
}

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----

?????文件??????57344??2013-07-15?10:08??update?material?shortage\update?material?shortage\bin\Debug\Interop.VBIDE.dll

?????文件??????????3??2013-07-15?10:33??update?material?shortage\update?material?shortage\bin\Debug\shortage_log.txt

?????文件??????77824??2013-07-15?11:33??update?material?shortage\update?material?shortage\bin\Debug\update?material?shortage.exe

?????文件??????32256??2013-07-15?11:33??update?material?shortage\update?material?shortage\bin\Debug\update?material?shortage.pdb

?????文件???????5632??2005-12-08?14:51??update?material?shortage\update?material?shortage\bin\Debug\update?material?shortage.vshost.exe

?????文件??????57344??2013-07-15?10:52??update?material?shortage\update?material?shortage\bin\Release\Interop.VBIDE.dll

?????文件??????????5??2013-07-15?11:57??update?material?shortage\update?material?shortage\bin\Release\shortage_log.txt

?????文件??????77824??2013-07-17?16:53??update?material?shortage\update?material?shortage\bin\Release\update?material?shortage.exe

?????文件??????30208??2013-07-17?16:53??update?material?shortage\update?material?shortage\bin\Release\update?material?shortage.pdb

?????文件???????5632??2005-12-08?14:51??update?material?shortage\update?material?shortage\bin\Release\update?material?shortage.vshost.exe

?????文件???????2408??2013-07-15?10:17??update?material?shortage\update?material?shortage\database.cs

?????文件???????9520??2013-07-17?16:54??update?material?shortage\update?material?shortage\Form1.cs

?????文件???????4689??2013-07-15?11:33??update?material?shortage\update?material?shortage\Form1.Designer.cs

?????文件??????86968??2013-07-15?11:33??update?material?shortage\update?material?shortage\Form1.resx

?????文件??????57344??2013-07-15?10:08??update?material?shortage\update?material?shortage\obj\Debug\Interop.VBIDE.dll

?????文件???????4608??2013-07-15?11:19??update?material?shortage\update?material?shortage\obj\Debug\TempPE\Properties.Resources.Designer.cs.dll

?????文件????????842??2013-07-15?11:33??update?material?shortage\update?material?shortage\obj\Debug\update?material?shortage.csproj.GenerateResource.Cache

?????文件????????679??2013-07-15?10:08??update?material?shortage\update?material?shortage\obj\Debug\update?material?shortage.csproj.ResolveComReference.cache

?????文件??????77824??2013-07-15?11:33??update?material?shortage\update?material?shortage\obj\Debug\update?material?shortage.exe

?????文件??????32256??2013-07-15?11:33??update?material?shortage\update?material?shortage\obj\Debug\update?material?shortage.pdb

?????文件??????54256??2013-07-15?11:33??update?material?shortage\update?material?shortage\obj\Debug\update_material_shortage.Form1.resources

?????文件????????180??2013-07-15?10:12??update?material?shortage\update?material?shortage\obj\Debug\update_material_shortage.Properties.Resources.resources

?????文件??????57344??2013-07-15?10:52??update?material?shortage\update?material?shortage\obj\Release\Interop.VBIDE.dll

?????文件???????4608??2013-07-17?16:54??update?material?shortage\update?material?shortage\obj\Release\TempPE\Properties.Resources.Designer.cs.dll

?????文件????????842??2013-07-15?11:39??update?material?shortage\update?material?shortage\obj\Release\update?material?shortage.csproj.GenerateResource.Cache

?????文件????????826??2013-07-17?16:53??update?material?shortage\update?material?shortage\obj\Release\update?material?shortage.csproj.ResolveComReference.cache

?????文件??????77824??2013-07-17?16:53??update?material?shortage\update?material?shortage\obj\Release\update?material?shortage.exe

?????文件??????30208??2013-07-17?16:53??update?material?shortage\update?material?shortage\obj\Release\update?material?shortage.pdb

?????文件??????54256??2013-07-17?16:53??update?material?shortage\update?material?shortage\obj\Release\update_material_shortage.Form1.resources

?????文件????????180??2013-07-17?16:53??update?material?shortage\update?material?shortage\obj\Release\update_material_shortage.Properties.Resources.resources

............此處省略24個文件信息

評論

共有 條評論

相關資源