这个问题太笼统了。明确点。
解决方案 »
- C#-TCP"请求的地址无效“
- 关于图片上传保存
- 发邮件发不出去
- ScriptMamager的Scripts属性调用外部的JS 为什么不行呢
- 一个解决方案中包括我个项目时如何发布.........................................................急???
- winform 中的汉字问题,如何编码?
- 业余时间写的一个论坛,愿与大家一起分享源代码,共同进步!
- 【入门】c#中的多层继承顺序和java的不一样,怎样才能一样?
- 送分了
- update a set a01=a01+'10' 这样更新在oracle里出错为什么?
- (100分!!)c#中如何指定axMediaPlayer播放文件的相对路径名?
- 点击combox 中的某一项,为什么不能正确的得到它的值,求救!!!代码如下:
public static Boolean ExecuteStrSQL(string strSQL)
{
//連接SQL數據庫
SqlConnection myConnection = new SqlConnection(ConfigurationSettings.AppSettings["StrSQLConnection"]);
SqlCommand myCommand = new SqlCommand(strSQL, myConnection);
myCommand.CommandType = CommandType.Text; // Execute the command
try
{
myConnection.Open();
myCommand.ExecuteNonQuery();
}
catch
{
return false;
}
return true;
}
还是挺详细的