相关考题

单项选择题 YouareimplementinganASP.NETMVC2Webapplicationthatcontainsthefollowingclass.PublicClassDepartmentControllerInheritsControllerShareddepartmentsAsList(OfDepartment)=NewList(OfDepartment)FunctionIndex()AsActionResultReturnView(departments)EndFunctionFunctionDetails(ByValidAsInteger)AsActionResultReturnView(departments.Find(Function(x)x.ID=id))EndFunctionFunctionListEmployees(ByValdAsDepartment)AsActionResultDimemployeesAsList(OfEmployee)=GetEmployees(d)ReturnView(employees)EndFunctionEndClassYoucreateastronglytypedviewthatdisplaysdetailsforaDepartmentinstance.Youwanttheviewtoalsoincludealistingofdepartmentemployees.YouneedtowriteacodesegmentthatwillcalltheListEmployeesactionmethodandoutputtheresultsinplace.Whichcodesegmentshouldyouuse?()

单项选择题 YouareimplementinganASP.NETMVC2Webapplicationthatcontainsseveralfolders.TheViews/Shared/DisplayTemplatesfoldercontainsatemplatedhelpernamedScore.ascxthatperformscustomformattingofintegervalues.TheModelsfoldercontainsaclassnamedPlayerwiththefollowingdefinition.PublicClassPlayerPublicPropertyNameAsStringPublicPropertyLastScoreAsIntegerPublicPropertyHighScoreAsIntegerEndClassYouneedtoensurethatthecustomformattingisappliedtoLastScorevalueswhentheHtmlHelper.DisplayForModelmethodiscalledforanyviewintheapplicationthathasamodeloftypePlayer.Whatshouldyoudo?()

单项选择题 YouareimplementinganASP.NETapplicationthatincludesapagenamedTestPage.aspx.TestPage.aspxusesamasterpagenamedTestMaster.master.YouaddthefollowingcodetotheTestPage.aspxcode-behindfiletoreadaTestMaster.masterpublicpropertynamedCityName.ProtectedSubPage_Load(ByValsenderAsObject,ByValeAsSystem.EventArgs)HandlesMe.LoadDimsAsString=Master.CityNameEndSubYouneedtoensurethatTestPage.aspxcanaccesstheCityNameproperty.Whatshouldyoudo?()