c#中连接数据库关于sqlconnection的用户sa无法登录的问题
来源:互联网 发布:淘宝短款溥针织开衫 编辑:程序博客网 时间:2024/05/18 02:26
今天看了使用Connection对象连接数据库,首先在SQLsever2005中附加了一个数据库MDF文件,然后在Visual studio中输入了以下SQLconnection代码:
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;
using System.Data.SqlClient;
namespace CloseSQL
{