Microsoft
70-573 · Question #2
70-573 Question #2: Real Exam Question with Answer & Explanation
Sign in or unlock 70-573 to reveal the answer and full explanation for question #2. The question stem and answer options stay visible for context.
Question
You have a SharePoint site collection. You plan to create a sandboxed solution that will contain a Web Part. The Web Part will display the title of the root Web. You write the following code segment for the Web Part. (Line numbers are included for reference only.) 02 03 Label currentTitle = new Label(); 04 currentTitle.Text = currentSite.RootWeb.Title; You add the Web Part to a page in the root Web and receive the following error message: "Web Part Error: Unhandled exception was thrown by the sandboxed code wrapper's Execute method in the partial trust app domain: An unexpected error has occurred." You need to prevent the error from occurring. What should you do?
Options
- AAdd the following line of code at line 02:
- BAdd the following line of code at line 02:
- CChange line 01 to the following code segment:
- DChange line 04 to the following code segment:
Unlock 70-573 to see the answer
You've previewed enough free 70-573 questions. Unlock 70-573 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.