You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.
You create a Web page named enterName.aspx. The Web page contains a TextBox control named txtName. The Web page cross posts to a page named displayName.aspx that contains a Label control named lblName.
You need to ensure that the lblName Label control displays the text that was entered in the txtName TextBox control.
Which code segment should you use?
A.
lblName.Text = Request.QueryString("txtName")
B.
Dim txtName As TextBox = TryCast(FindControl("txtName"), TextBox)
lblName.Text = txtName.Text
C.
Dim txtName As TextBox = TryCast(Parent.FindControl("txtName"), TextBox)
lblName.Text = txtName.Text
D.
Dim txtName As TextBox = TryCast(PreviousPage.FindControl("txtName"), TextBox)
lblName.Text = txtName.Text