資源簡(jiǎn)介
一個(gè)簡(jiǎn)單的汽車(chē)管理系統(tǒng) 附帶數(shù)據(jù)庫(kù)。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。

代碼片段和文件信息
using?System;
using?System.Collections.Generic;
using?System.Linq;
using?System.Text;
using?System.Threading.Tasks;
using?System.Data.SqlClient;
using?System.Data;
namespace?FrmCar
{
????class?DBhelper
????{
????????//數(shù)據(jù)庫(kù)連接字符串
????????private?string?ConnString?=?@“Data?Source=.;Initial?Catalog=AutoSys;User?ID=sa;Password=123“;
????????//數(shù)據(jù)庫(kù)連接Connection對(duì)象
????????private?SqlConnection?connection;
????????public?SqlConnection?Connection
????????{
????????????get
????????????{
????????????????if?(connection?==?null)
????????????????{
????????????????????connection?=?new?SqlConnection(ConnString);
????????????????}
????????????????return?connection;
????????????}
????????}
????????//打開(kāi)數(shù)據(jù)庫(kù)連接
????????public?void?OpenConnection()
????????{
????????????if?(Connection.State?==?ConnectionState.Closed)
????????????{
????????????????Connection.Open();
????????????}
????????????else?if?(Connection.State?==?ConnectionState.Broken)
????????????{
????????????????Connection.Close();
????????????????Connection.Open();
????????????}
????????}
????????//關(guān)閉數(shù)據(jù)庫(kù)連接
????????public?void?CloseConnection()
????????{
????????????if?(Connection.State?==?ConnectionState.Open?||?Connection.State?==?ConnectionState.Broken)
????????????{
????????????????Connection.Close();
????????????}
????????}
????}
}
?屬性????????????大小?????日期????時(shí)間???名稱(chēng)
-----------?---------??----------?-----??----
?????文件????3145728??2018-02-25?11:43??34227320李云鵬\AutoSys.mdf
?????文件????1048576??2018-02-25?11:43??34227320李云鵬\AutoSys_log.ldf
?????文件????????187??2018-02-25?09:57??34227320李云鵬\FrmCar\FrmCar\App.config
?????文件??????19968??2018-02-25?11:42??34227320李云鵬\FrmCar\FrmCar\bin\Debug\FrmCar.exe
?????文件????????187??2018-02-25?09:57??34227320李云鵬\FrmCar\FrmCar\bin\Debug\FrmCar.exe.config
?????文件??????46592??2018-02-25?11:42??34227320李云鵬\FrmCar\FrmCar\bin\Debug\FrmCar.pdb
?????文件??????22984??2018-02-25?11:42??34227320李云鵬\FrmCar\FrmCar\bin\Debug\FrmCar.vshost.exe
?????文件????????187??2018-02-25?09:57??34227320李云鵬\FrmCar\FrmCar\bin\Debug\FrmCar.vshost.exe.config
?????文件???????1406??2018-02-25?10:29??34227320李云鵬\FrmCar\FrmCar\DBhelper.cs
?????文件???????1624??2018-02-25?11:33??34227320李云鵬\FrmCar\FrmCar\FormMain.cs
?????文件???????6658??2018-02-25?10:25??34227320李云鵬\FrmCar\FrmCar\FormMain.Designer.cs
?????文件???????6015??2018-02-25?10:25??34227320李云鵬\FrmCar\FrmCar\FormMain.resx
?????文件???????4503??2018-02-25?10:44??34227320李云鵬\FrmCar\FrmCar\FrmCar.csproj
?????文件???????3663??2018-02-25?11:43??34227320李云鵬\FrmCar\FrmCar\FrmLogin.cs
?????文件???????9149??2018-02-25?11:43??34227320李云鵬\FrmCar\FrmCar\FrmLogin.Designer.cs
?????文件???????5817??2018-02-25?11:43??34227320李云鵬\FrmCar\FrmCar\FrmLogin.resx
?????文件???????2743??2018-02-25?11:43??34227320李云鵬\FrmCar\FrmCar\FrmSelectCar.cs
?????文件???????7537??2018-02-25?11:43??34227320李云鵬\FrmCar\FrmCar\FrmSelectCar.Designer.cs
?????文件???????8037??2018-02-25?11:43??34227320李云鵬\FrmCar\FrmCar\FrmSelectCar.resx
?????文件????????863??2018-02-25?09:57??34227320李云鵬\FrmCar\FrmCar\obj\Debug\DesignTimeResolveAssemblyReferences.cache
?????文件???????7055??2018-02-25?10:27??34227320李云鵬\FrmCar\FrmCar\obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache
?????文件???????1077??2018-02-25?11:42??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.csproj.FileListAbsolute.txt
?????文件???????1104??2018-02-25?11:34??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.csproj.GenerateResource.Cache
?????文件???????2209??2018-02-25?10:25??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.csprojResolveAssemblyReference.cache
?????文件??????19968??2018-02-25?11:42??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.exe
?????文件????????180??2018-02-25?10:44??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.FormMain.resources
?????文件????????180??2018-02-25?11:34??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.FrmLogin.resources
?????文件????????180??2018-02-25?11:34??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.FrmSelectCar.resources
?????文件??????46592??2018-02-25?11:42??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.pdb
?????文件????????180??2018-02-25?10:44??34227320李云鵬\FrmCar\FrmCar\obj\Debug\FrmCar.Properties.Resources.resources
............此處省略24個(gè)文件信息
評(píng)論
共有 條評(píng)論