Accelerated Ideas - Software Solutions for Today's world
Free Practice Exam - MCPD 70-562


Control Panel

Exam Progress



Move on to the next question




Links

Home
Microsoft Exams





Question 3

You’ve just created a new form for your HR department that shows all the employees for the selected office. This form uses a Repeater control to display data, each item in the Repeater contains just a single Label control to show the employee name. Users enter the office name into a textbox and click search to find the employees, the application then finds the employees and binds a strongly typed List to the repeater control.

However, you now need some special functionality that displays the employee name in capitals if they are a manager. You have encapsulated this functionality into a method called GetEmployeeName() which is in your code behind file for the page. Which line of code could you use to get the correct string to display?








The correct answer is '<%# GetEmployeeName(Container.DataItem) %>'. This line of code will call the GetEmployeesName function passing the current DataItem object. The function can return a string object based on the employee type i.e. if they’re a manager then the result is capitalized.



 
Sponsored






Free practice exams are provided free of charge by Accelerated Ideas. Please respect our exams and do not reproduce our material or abuse the testing system. Thank you. Microsoft exams for MCPD, MCTS, MCP, MCSE, MCSA, MCAD, MCSD