if i put
ProjectName.DataBind();
after the records are come in radlistbox if i don't put that record are shown one time but for each doesn't go inside
see the screen shot
.cs
if (service[0].grupname.ToString() == "SubCon")
{
using (var db = new DoskContractServicesDataContext(Globals.strCon))
{
var Projec = (from a in db.DSProjectMasters where a.FinalStatus == "Cls" && a.Status != "Del" select new { a.ProjectCode, a.ProjectTitle }).ToList();
ProjectName.DataSource = Projec;
ProjectName.DataValueField = "ProjectCode";
ProjectName.DataTextField = "ProjectTitle";
ProjectName.DataBind();
}
ProjNam.Visible = true;
ProjectName.Visible = true;
string md = service[0].Projectid.ToString();
string[] Projid = md.Split(',');
for (int i = 0; i < Projid.Length; i++)
{
string val = Projid[i].ToString();
int m = 0;
foreach (RadListBoxItem item1 in ProjectName.Items)
{
string Md1 = ProjectName.Items[m].Value;
if (Md1 == val)
{
item1.Checked = true;
}
m++;
}
}
}
Thanks Advance,
Mohamed.