PrepAway - Latest Free Exam Questions & Answers

Category: 70-573

Exam 70-573: TS: Microsoft SharePoint 2010, Application Development

What should you do?

You plan to create two Web Parts named Products and ProductDetails. You create an interface that contains the following code segment.

public interface Interface1
{
string Productid { get; set; }
}

You need to ensure that the Products Web Part sends ProductId to the ProductDetails Web Part. You must achieve this goal by using the ASP.NET Web Part connection framework.

What should you do?

What should you do?

You plan to create two Web Parts named Products and ProductDetails. You create an interface that contains the following code segment.

public interface Interface1
{
string Productid { get; set; }
}

You need to ensure that the Products Web Part sends ProductId to the ProductDetails Web Part. You must achieve this goal by using the ASP.NET Web Part connection framework.

What should you do?

What should you do?

You create a Web Part that contains the following code segment. (Line numbers are included for reference only.)

01 public class WebPart1 : WebPart
02 {
03 public WebPart1() {}
04
05 protected override void CreateChildControls()
06 {
07 Button clickButton = new Button();
08
09 base.CreateChildControls();
10 }
11
12 protected override void RenderContents(HtmlTextWriter writer)
13 {
14
15 base.RenderContents(writer);
16 }
17 }

You discover that the clickButton button does not appear.

You need to ensure that clickButton appears.

What should you do?

Which code segment should you add to the console application?

You have a custom theme named MyTheme. The theme is defined in a file named MyTheme.thmx.

You have a console application that contains the following code segment. (Line numbers are included for reference only.)

01 using (SPSite site=new SPSite(http://intranet))
02 {
03 SPWeb web=site.OpenWeb();
04
05 }

You need to programmatically apply the theme to a SharePoint site.

Which code segment should you add to the console application?

Which code segment should you add at line 04?

You are creating an application.

You develop a custom control that renders a contextual tab. The control contains the following code segment. (Line numbers are included for reference only.)

01 protected override void OnPreRender(EventArgs e)
02 {
03 SPRibbon curRibbon = SPRibbon.GetCurrent(this.Page);
04
05 curRibbon.MakeContextualGroupInitiallyVisible(“SP.Ribbon.ContextualGroup”, string.Empty);
06 base.OnPreRender(e);
07 }

You need to ensure that when the custom control is rendered, the custom contextual tab appears in the Ribbon.

Which code segment should you add at line 04?

Which code segment should you add to the Web Part?

You create a Feature named Feature1. Feature1 is activated in a SharePoint site.

You create a Web Part that contains the following code.

SPSite site = new SPSite(“http://intranet/site1”);
SPWeb web = site.OpenWeb();
SPFeatureDefinition feature = SPFarm.Local.FeatureDefinitions[“Feature1”];

You need to modify the Web Part to activate Feature1 in Site1 only.

Which code segment should you add to the Web Part?


Page 12 of 18« First...1011121314...Last »