SPSite spSite = new SPSite(Utility.GetTopLevelSiteUrl());
SPWeb tempSite = spSite.OpenWeb();
SPList splst = tempSite.Lists["T_Opportunity"];
SPQuery query = new SPQuery();
strResult = Convert.ToString(query);
SPListItemCollection colListItems = splst.GetItems(query);
SPListItem oitemlist = colListItems[0];
string createdBy = Convert.ToString(oitemlist["PreEngagementMQ1"]);
if (!string.IsNullOrEmpty(createdBy) && createdBy.Contains("#"))
{
createdBy = createdBy.Substring(createdBy.LastIndexOf("#") + 1);
}
txtpreengagementMQ1.Text = createdBy;
txtpreengagementMQ2.Text = currentOpportunityItem.PreEngagementMQ2Title;
Iam unable to bind the data to text box .Actually txtpreengagementMQ1 and txtpreengagementMQ2 have to bind.But here In my code I written for one.That one also not binding.please give some suggesstions on it.