please help me and look to this code
- string mainconn = ConfigurationManager.ConnectionStrings["Con_VisitorsControl"].ConnectionString;
- SqlConnection sqlconn = new SqlConnection(mainconn);
- string sqlquery = "select VisitorName, IqamaCopy from [dbo].[tbl_Visitors] where VisitorId = ' " + txtno.Text + " ' ";
- SqlCommand sqlcomm = new SqlCommand(sqlquery, sqlconn);
- sqlconn.Open();
- SqlDataAdapter sda = new SqlDataAdapter();
- sda.SelectCommand = sqlcomm;
- DataSet ds = new DataSet();
- sda.Fill(ds);
- DataList1.DataSource = ds;
- DataList1.DataBind();
- sqlconn.Close();
this VisitorId Is Nvarchar contain to 9 digits on sql how can i select and convert this fieldname in the c#
thanks