0

what i did so for

var allLiveIDS = Request.Form.AllKeys.Where(key => key.Contains("txt")).ToList();
for (int i = 2; i < allLiveIDS.Count; i++)
        {
          var Textt= this.FindControl(allLiveIDS[i]) as TextBox;
            Textt.Text = "Some Value";
}

but getting null in Textt, pLease share how can i set value to text box

  • Is this WebForms? – Dzyann Feb 16 '18 at 14:08
  • Based on the assumption that this is webforms, I'd recommend to check out this SO post. The answer to that post will guide you to a solution how to find your controls in the control tree: https://stackoverflow.com/questions/4955769/better-way-to-find-control-in-asp-net – Schadensbegrenzer Feb 16 '18 at 14:40

0 Answers0