کمک

leg_big

Member
سلام
بچه ها کمک ، جون ............ کمک کنید ، اقای مدیر انجمن این پست ما رو پاک نکنید ، لطفا :D

من وقتی می خوام دو یه دیتابیس حروف اضافه کنم ، این خطا رو میگیره !!!!
:cry: :cry: :cry: :cry: :cry: :cry: :cry: :cry: :cry:

Server Error in '/InternalService' Application.
--------------------------------------------------------------------------------

The name 'a' is not permitted in this context. Only constants, expressions, or variables allowed here. Column names are not permitted.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException: The name 'a' is not permitted in this context. Only constants, expressions, or variables allowed here. Column names are not permitted.

Source Error:


Line 66: SqlCommand sqlcommandUsers = new SqlCommand(insertCmd, SqlConnectionCompany);
Line 67: sqlcommandUsers.Connection.Open();
Line 68: sqlcommandUsers.ExecuteNonQuery();
Line 69: sqlcommandUsers.Connection.Close();
Line 70: Label1.Text="اطلاعات ثبت شد";


Source File: c:\inetpub\wwwroot\internalservice\newcompany.aspx.cs Line: 68

Stack Trace:


[SqlException: The name 'a' is not permitted in this context. Only constants, expressions, or variables allowed here. Column names are not permitted.]
System.Data.SqlClient.SqlCommand.ExecuteNonQuery() +182
InternalService.WebForm1.Button1_Click(Object sender, EventArgs e) in c:\inetpub\wwwroot\internalservice\newcompany.aspx.cs:68
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +108
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1277




--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573​
 

MCSD

Banned
شما Connection خدوتونه رو Open کردید ؟
آیا نام ستون درجدول موجود میباشد ؟
 

جدیدترین ارسال ها

بالا