PrepAway - Latest Free Exam Questions & Answers

Which two actions should you perform?

You are developing an ASP.NET web page named WebPage.aspx.
The page includes a user control named UserInfoControl.ascx.
You need to expose a control property named FirstName and read its value from the page.
Which two actions should you perform? (Each correctanswer presents part of the solution. Choose two.)

PrepAway - Latest Free Exam Questions & Answers

A.
Add the following code segment to UserInfoControl.ascx.cs:
protected string FirstName { get; set; }

B.
Add the following code segment to UserInfoControl.ascx.cs:
public string FirstName { get; set; }

C.
Add the following code segment to WebPage.aspx.cs:
var firstName = UserInfoControl1.Attributes[“FirstName”];

D.
Add the following code segment to WebPage.aspx.cs:
var firstName = UserInfoControl1.FirstName;


Leave a Reply