Home » FAQ » ASP.NET » TextBox » Why do I get error message ‘Option Strict On disallows implicit conversions from ‘System.Web.UI.Control’ to ‘System.Web.UI.WebControls.TextBox’.’
For type Casting apply the following steps
VB.NET
dim aprtxt as string aprtxt= CType(e.Item.FindControl('txtapr'), TextBox)
C#
string aprtxt; aprtxt = (TextBox) e.Item.FindControl['txtapr'];
Platform BlazorASP.NETWinFormsWPF.NET MAUI
Question *
Answer (Optional)
Email (Optional)
Email address is only for further clarification on your FAQ request. It will not be used for any other purpose.
Please leave this field empty.
Share with