2013年11月25日星期一

最高の参考書でMicrosoft 070-506認定試験に合格しよう

JapanCertはIT技術を勉強している人がよく知っているウェブサイトです。このサイトはIT認定試験を受けた受験生から広く好評されました。これはあなたに本当のヘルプを与えるサイトです。では、なぜJapanCertは皆さんの信頼を得ることができますか。それはJapanCertにはIT業界のエリートのグループがあって、グループのIT専門家達がずっと皆さんに最高の070-506資料を提供することに力を尽くしていますから。したがって、JapanCertは優れた参考書を提供して、みなさんのニーズを満たすことができます。

Microsoftの070-506の認定試験に合格すれば、就職機会が多くなります。この試験に合格すれば君の専門知識がとても強いを証明し得ます。Microsoftの070-506の認定試験は君の実力を考察するテストでございます。

試験番号:070-506問題集
試験科目:Microsoft 「Microsoft Silverlight 4, Development」
最近更新時間:2013-11-24
問題と解答:153

JapanCertのMicrosoftの070-506試験のトレーニングキットはJapanCertのIT技術専門家たちによって開発されたのです。そのデザインは当面の急速に変化するIT市場と密接な関係があります。JapanCertのトレーニングはあなたを助けて継続的に発展している技術を利用して、問題を解決する能力を高めると同時に仕事についての満足度を向上させることができます。JapanCertのMicrosoftの070-506の認証したカバー率は100パーセントに達したのですから、弊社の問題と解答を利用する限り、あなたがきっと気楽に試験に合格することを保証します。

JapanCertの070-506問題集は的中率が高いですから、あなたが一回で試験に合格するのを助けることができます。これは多くの受験生たちによって証明されたことです。ですから、問題集の品質を心配しないでください。これは間違いなくあなたが一番信頼できる070-506試験に関連する資料です。まだそれを信じていないなら、すぐに自分で体験してください。そうすると、きっと私の言葉を信じるようになります。

難しいIT認証試験に受かることを選んだら、頑張って準備すべきです。JapanCertのMicrosoftの070-506試験トレーニング資料はIT認証試験に受かる最高の資料で、手に入れたら成功への鍵を持つようになります。JapanCertのMicrosoftの070-506試験トレーニング資料は信頼できるもので、100パーセントの合格率を保証します。

ショートカットを選択し、テクニックを使用するのはより良く成功できるからです。070-506認定試験に一発合格できる保障を得たいなら、JapanCert の070-506問題集はあなたにとってユニークな、しかも最良の選択です。これは賞賛の声を禁じえない参考書です。この問題集より優秀な試験参考書を見つけることができません。この070-506問題集では、あなたが試験の出題範囲をより正確に理解することができ、よりよく試験に関連する知識を習得することができます。そして、もし試験の準備をするが足りないとしたら、070-506問題集に出る問題と回答を全部覚えたらいいです。この問題集には実際の070-506試験問題のすべてが含まれていますから、それだけでも試験に受かることができます。

070-506認定試験について、あなたはどうやって思っているのですか。非常に人気があるMicrosoftの認定試験の一つとして、この試験も大切です。しかし、試験の準備をよりよくできるために試験参考書を探しているときに、優秀な参考資料を見つけるのはたいへん難しいことがわかります。では、どうしたらいいでしょうか。大丈夫ですよ。JapanCertはあなたの望みを察して、受験生の皆さんの要望にこたえるために、一番良い試験070-506問題集を提供してあげます。

購入前にお試し,私たちの試験の質問と回答のいずれかの無料サンプルをダウンロード:http://www.japancert.com/070-506.html

NO.1 You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4.
The application contains the following XAML fragment.
<TextBlock x:Name="QuoteOfTheDay" />
The application calls a Windows Communication Foundation (WCF) service named MyService that
returns the quote of the day and assigns it to the QuoteOfTheDay TextBlock.
The application contains the following code segment. (Line numbers are included for reference only.)
01 var client = new MyService.MyServiceClient()
02 client.GetQuoteOfTheDayCompleted += (s, args) => QuoteOfTheDay.Text = args.Result
03 client.GetQuoteOfTheDayAsync()
You need to handle errors that might occur as a result of the service call. You also need to provide a
default value of "Unavailable" when an error occurs.
Which code segment should you replace at lines 02 and 03?
A. QuoteOfTheDay.Text = "Unavailable"
client.GetQuoteOfTheDayCompleted += (s, args) => QuoteOfTheDay.Text = args.Result
client.GetQuoteOfTheDayAsync()
B. client.GetQuoteOfTheDayCompleted += (s, args) =>
{
if (args.Result != null)
{
QuoteOfTheDay.Text = args.Result
}
else
{
QuoteOfTheDay.Text = "Unavailable"
}
}
client.GetQuoteOfTheDayAsync()
C. client.GetQuoteOfTheDayCompleted += (s, args) => QuoteOfTheDay.Text = args.Result
try
{
client.GetQuoteOfTheDayAsync()
}
catch (Exception ex)
{
// TODO: handle exception
QuoteOfTheDay.Text = "Unavailable"
}
D. client.GetQuoteOfTheDayCompleted += (s, args) =>
{
if (args.Error == null)
{
QuoteOfTheDay.Text = args.Result
}
else
{
// TODO: handle error
QuoteOfTheDay.Text = "Unavailable"
}
}
client.GetQuoteOfTheDayAsync()
Answer: D

Microsoft   070-506   070-506   070-506

NO.2 statusTextBlock.Text = e.ProgressPercentage + "%"

NO.3 You have a Silverlight 4 application that uses isolated storage. You create an application that has a 5
MB file that must be saved to isolated storage.
Currently, the application has not allocated enough isolated storage to save the file.
You need to ensure that the application prompts the user to increase the isolated storage allocation. You
also need to ensure that only the minimum amount of space needed to save the 5 MB file is requested.
Which code segment should you use?
A. using (var store = IsolatedStorageFile.GetUserStoreForApplication())
{
var neededSpace = 5242880
if (store.IncreaseQuotaTo(neededSpace))
{
...
}
}
B. using (var store = IsolatedStorageFile.GetUserStoreForApplication())
{
var neededSpace = 5242880
if (store.IncreaseQuotaTo(store.Quota + neededSpace))
{
...
}
}
C. using (var store = IsolatedStorageFile.GetUserStoreForApplication())
{
var neededSpace = 5242880
if (store.IncreaseQuotaTo(
store.AvailableFreeSpace + neededSpace
))
{
...
}
}
D. using (var store = IsolatedStorageFile.GetUserStoreForApplication())
{
var neededSpace = 5242880
if (store.IncreaseQuotaTo(
store.UsedSize + neededSpace
))
{
...
}
}
Answer: D

Microsoft過去問   070-506練習問題   070-506   070-506認定資格   070-506認定証

NO.4 You are developing a Silverlight 4 application. You define an Invoice object according to the following
code segment.
public class Invoice
{
public int InvoiceId { get
set
}
public double Amount { get
set
}
public Supplier Supplier { get
set
}
public DateTime InvoiceDate { get
set
}
public DateTime PayDate { get
set
}
public string InvoiceDescription { get
set
}
}
You need to display a list of invoices that have the following properties displayed on each line: InvoiceId,
Amount, and InvoiceDate.
Which XAML fragment should you use?
A. <ListBox x:Name="InvoiceListBox">
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding Path=InvoiceId}" />
<TextBlock Text="{Binding Path=Amount}" />
<TextBlock Text="{Binding Path=InvoiceDate}" />
</StackPanel>
</ListBox>
B. <ListBox x:Name="InvoiceListBox">
<StackPanel Orientation="Horizontal">
<ListBoxItem>
<TextBlock Text="{Binding Path=InvoiceId}" />
</ListBoxItem>
<ListBoxItem>
<TextBlock Text="{Binding Path=Amount}" />
</ListBoxItem>
<ListBoxItem>
<TextBlock Text="{Binding Path=InvoiceDate}" />
</ListBoxItem>
</StackPanel>
</ListBox>
C. <ListBox x:Name="InvoiceListBox">
<ListBox.Items>
<ItemsPanelTemplate>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding Path=InvoiceId}" />
<TextBlock Text="{Binding Path=Amount}" />
<TextBlock Text="{Binding Path=InvoiceDate}" />
</StackPanel>
</ItemsPanelTemplate>
</ListBox.Items>
</ListBox>
D. <ListBox x:Name="InvoiceListBox">
<ListBox.ItemTemplate>
<DataTemplate>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding Path=InvoiceId}" />
<TextBlock Text="{Binding Path=Amount}" />
<TextBlock Text="{Binding Path=InvoiceDate}" />
</StackPanel>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
Answer: D

Microsoft参考書   070-506認証試験   070-506認定資格   070-506認定資格   070-506

NO.5 }
You need to ensure that worker can be properly canceled.
Which code segment should you use to replace line 11?
A. var cancel = (sender as BackgroundWorker).CancellationPending
if(cancel) {
(sender as BackgroundWorker).CancelAsync()
break
}
else {
InvokeLongRunningProcessStep()
}
B. var cancel = (sender as BackgroundWorker).CancellationPending
if(cancel) {
e.Cancel = true
break
}
else {
InvokeLongRunningProcessStep()
}
C. var cancel = e.Cancel
if(cancel) {
(sender as BackgroundWorker).CancelAsync()
break
}
else {
InvokeLongRunningProcessStep()
}
D. var cancel = e.Cancel
if(cancel) {
e.Cancel = true
break
}
else {
InvokeLongRunningProcessStep()
}
Answer: B

Microsoft認定試験   070-506   070-506認証試験
12.You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4.
You add a BackgroundWorker object named worker to the application. You also add a CheckBox control
named checkBox and a TextBlock control named statusTextBlock.
You add the following code segment. (Line numbers are included for reference only.)
01 public MainPage()
02 {
03 InitializeComponent()
04 worker.WorkerReportsProgress = true
05 worker.DoWork += new DoWorkEventHandler(worker_DoWork)
06 worker.ProgressChanged += new ProgressChangedEventHandler(worker_ProgressChanged)
07 }
08 private void worker_DoWork(object sender, DoWorkEventArgs e)
09 {
10 for (int i = 0
i < 100
i++) {
11 bool isChecked = checkBox.IsChecked.HasValue && checkBox.IsChecked.Value
12 ExecuteLongRunningProcessStep(isChecked)
13 worker.ReportProgress(i)

NO.6 }

NO.7 You are developing a Silverlight 4 application.
You have a collection named ColPeople of the List<Person> type. You define the Person class according
to the following code segment.
public class Person
{
public string Name {get
set }
public string Description { get
set
}
public string Gender { get
set
}
public int Age { get
set
}
public int Weight { get
set
}
}
You need to bind ColPeople to a ComboBox so that only the Name property is displayed.
Which XAML fragment should you use?
A. <ComboBox DataContext="{Binding ColPeople}" ItemsSource="{Binding ColPeople}"
DisplayMemberPath="Name" />
B. <ComboBox DataContext="{Binding Person}" ItemsSource="{Binding Person}"
DisplayMemberPath="ColPeople" />
C. <ComboBox DataContext="{Binding ColPeople}" DisplayMemberPath="Name" />
D. <ComboBox DataContext="{Binding Person}" />
Answer: A

Microsoft   070-506認証試験   070-506認証試験   070-506練習問題   070-506問題集

NO.8 You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4.
You create a Windows Communication Foundation (WCF) Data Service. You add a service reference to
the WCF Data Service named NorthwindEntities in the Silverlight application. You also add a
CollectionViewSource object named ordersViewSource in the Silverlight application.
You add the following code segment. (Line numbers are included for reference only.)
01 void getOrders_Click(object sender, RoutedEventArgs e)
02 {
03 var context = new NorthwindEntities()
04
05 var query = from order in context.Orders
06 select order
07
08 }
You need to retrieve the Orders data from the WCF Data Service and bind the data to the
ordersViewSource object.
Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.)
A. Add the following code segment at line 04.
var obsCollection = new ObservableCollection<Order>()
B. Add the following code segment at line 04.
var dsOrders = new DataServiceCollection<Order>()
dsOrders.LoadCompleted += new EventHandler<LoadCompletedEventArgs>(
(dsc, args) =>
{
ordersViewSource.Source = dsOrders
})
C. Add the following code segment at line 07.
dsOrders.LoadAsync(query)
D. Add the following code segment at line 07.
dsOrders.Load(query)
E. Add the following code segment at line 07.
query.ToList().ForEach(o => obsCollection.Add(o))
ordersViewSource.Source = obsCollection
Answer: B, C

Microsoft   070-506   070-506練習問題   070-506   070-506

NO.9 You are developing a Silverlight 4 application.
The application contains an XAML page that defines the following Grid control.
<Grid Name="gridBody" >
<Grid.RowDefinitions>
<RowDefinition />
<RowDefinition />
</Grid.RowDefinitions>
<TextBlock Text="Employee Info" />
<TextBlock Text="Please enter employee info" Grid.Row="1" Height="20" VerticalAlignment="Top" />
<TextBox x:Name="EmpInfo" Grid.Row="1" Margin="0,25,0,0" TextWrapping="Wrap" />
...
</Grid>
The codebehind file for myPage.xaml contains the following code segment. (Line numbers are included
for reference only.)
01 public myPage()
02 {
03 InitializeComponent()
04
05 UserControl control = new MyCustomControl()
06
07 }
You need to replace the contents of the second row of gridBody with a user control of the
MyCustomControl type.
Which code segment should you insert at line 06?
A. gridBody.Children.Insert(1, control)
B. gridBody.RowDefinitions.Remove(gridBody.RowDefinitions[1])
gridBody.Children.Insert(1, control)
C. gridBody.Children.Clear()
Grid.SetRow(control, 1)
gridBody.Children.Add(control)
D. List<UIElement> remove = gridBody.Children.Where(c => c is FrameworkElement &&
Grid.GetRow((FrameworkElement)c) == 1).ToList()
foreach (UIElement element in remove)
{
gridBody.Children.Remove(element)
}
Grid.SetRow(control, 1)
gridBody.Children.Add(control)
Answer: D

Microsoft認定証   070-506認定試験   070-506問題集   070-506認証試験   070-506

NO.10 You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4.
You create a new user control in the application. You add the following XAML fragment to the control.
<StackPanel KeyDown="App_KeyDown"
Orientation="Vertical">
<TextBox x:Name="firstName" />
<TextBox x:Name="lastName" />
<TextBox x:Name="address" />
</StackPanel>
You add the following code segment in the codebehind file of the control. (Line numbers are included for
reference only.)
01 private void App_KeyDown(object sender, KeyEventArgs e)
02 {
03
04 }
05
06 private void FirstAndLastNameKeyDown()
07 {
08...
09 }
You need to ensure that the FirstAndLastNameKeyDown method is invoked when a key is pressed while
the focus is on the firstName or lastName TextBox controls. You also need to ensure that the default
behavior of the controls remains unchanged.
Which code segment should you add at line 03?
A. if (((FrameworkElement)sender).Name == "firstName" ||
((FrameworkElement)sender).Name == "lastName")
{
FirstAndLastNameKeyDown()
}
e.Handled = false
B. if (((FrameworkElement)sender).Name == "firstName" ||
((FrameworkElement)sender).Name == "lastName")
{
FirstAndLastNameKeyDown()
}
e.Handled = true
C. if (((FrameworkElement)e.OriginalSource).Name == "firstName" ||
((FrameworkElement)e.OriginalSource).Name == "lastName")
{
FirstAndLastNameKeyDown()
}
e.Handled = false
D. if (((FrameworkElement)e.OriginalSource).Name == "firstName" ||
((FrameworkElement)e.OriginalSource).Name == "lastName")
{
FirstAndLastNameKeyDown()
}
e.Handled = true
Answer: C

Microsoft練習問題   070-506   070-506練習問題   070-506練習問題

NO.11 }

NO.12 You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4.
You add a BackgroundWorker object named worker to the application.
You add the following code segment. (Line numbers are included for reference only.)
01 public MainPage()
02 {
03 InitializeComponent()
04 worker.WorkerSupportsCancellation = true
05 worker.DoWork += new DoWorkEventHandler(worker_DoWork)
06 worker.RunWorkerCompleted += new RunWorkerCompletedEventHandler(worker_Completed)
07 }
08 private void worker_DoWork(object sender, DoWorkEventArgs e)
09 {
10 for (int i = 0
i < 100
i++) {
11 InvokeLongRunningProcessStep()

NO.13 You are developing a Silverlight 4 application.
The application defines the following XAML fragment. (Line numbers are included for reference only.)
01 <ComboBox>
02 <ComboBoxItem Content="Item 1" />
03 <ComboBoxItem Content="Item 2" />
04 <ComboBoxItem Content="Item 3" />
05 </ComboBox>
The codebehind file contains the following code segment. (Line numbers are included for reference only.)
06 void PrintText(object sender, SelectionChangedEventArgs args){
07
08 MessageBox.Show( "You selected " + cbi.Content.ToString() + ".")
09 }
You need to ensure that when the user selects an item in a ComboBox control, the content of the item is
displayed.
What should you do?
A. Replace the following XAML fragment at line 01.
<ComboBox SelectionChanged="PrintText">
Add the following code segment at line 07.
ComboBoxItem cbi = ((sender as ComboBox).SelectedItem as ComboBoxItem)
B. Replace the following XAML fragment at line 01.
<ComboBox SelectionChanged="PrintText">
Add the following code segment at line 07.
ComboBoxItem cbi = ((sender as ComboBox).SelectedIndex as ComboBoxItem)
C. Replace the following XAML fragment at line 01.
<ComboBox DropDownClosed="PrintText">
Add the following code segment at line 07.
ComboBoxItem cbi = ((sender as ComboBox).SelectedItem as ComboBoxItem)
D. Replace the following XAML fragment at line 01.
<ComboBox DropDownClosed="PrintText">
Add the following code segment at line 07.
ComboBoxItem cbi = ((sender as ComboBox).SelectedIndex as ComboBoxItem)
Answer: A

Microsoft認定資格   070-506問題集   070-506   070-506過去問   070-506

NO.14 {

NO.15 You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4. The
application has a TextBox control named txtName.
You need to handle the event when txtName has the focus and the user presses the F2 key.
Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.)
A. txtName.KeyDown += new KeyEventHandler(txtName_KeyDown)
B. txtName.LostFocus += new RoutedEventHandler(txtName_LostFocus)
C. txtName.TextChanged += new TextChangedEventHandler(txtName_TextChanged)
D. void txtName_TextChanged(object sender, TextChangedEventArgs e)
{
if ((Key)e.OriginalSource == Key.F2)
{
//Custom logic
}
}
E. void txtName_KeyDown(object sender, KeyEventArgs e)
{
if (e.Key == Key.F2)
{
//Custom logic
}
}
F. void txtName_LostFocus(object sender, RoutedEventArgs e)
{
if ((Key)e.OriginalSource == Key.F2)
{
//Custom logic
}
}
Answer: A, E

Microsoft   070-506練習問題   070-506過去問   070-506過去問

NO.16 private void worker_ProgressChanged(object sender, ProgressChangedEventArgs e)

NO.17 You are developing a Silverlight 4 application. You define the visual behavior of a custom control in the
ControlTemplate by defining a VisualState object named Selected.
You need to change the visual state of the custom control to the Selected state.
Which code segment or XAML fragment should you use?
A. VisualStateManager.GoToState( this, "Selected", true )
B. <VisualTransition To="Selected">
<Storyboard>
...
</Storyboard>
</VisualTransition>
C. <VisualTransition From="Selected">
<Storyboard>
...
</Storyboard>
</VisualTransition>
D. public static readonly DependencyProperty SelectedProperty =
DependencyProperty.Register("Selected", typeof(VisualState), typeof(MyControl), null)
public VisualState Selected
{
get { return (VisualState)GetValue(SelectedProperty)
}
set { SetValue(SelectedProperty, value)
}
}
Answer: A

Microsoft認定証   070-506認定試験   070-506参考書   070-506

NO.18 }

NO.19 }
You attempt to run the application. You receive the following error message:
"Invalid crossthread access."
You need to ensure that worker executes successfully.
What should you do?
A. Replace line 11 with the following code segment.
var b = (bool )checkBox.GetValue(CheckBox.IsCheckedProperty)
bool isChecked = b.HasValue && b.Value
B. Replace line 11 with the following code segment.
bool isChecked = false
Dispatcher.BeginInvoke(() =>
{
isChecked = checkBox.IsChecked.HasValue && checkBox.IsChecked.Value
})
C. Replace line 18 with the following code segment.
statusTextBlock.SetValue(TextBlock.TextProperty, e.ProgressPercentage + "%")
D. Replace line 18 with the following code segment.
Dispatcher.BeginInvoke(() =>
{
statusTextBlock.Text = e.ProgressPercentage + "%"
})
Answer: B

Microsoft練習問題   070-506   070-506
13.You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4.
You add the following code segment. (Line numbers are included for reference only.)
01 public class MyControl : Control
02 {
03
04 public string Title
05 {
06 get { return (string)GetValue(TitleProperty)
}
07 set { SetValue(TitleProperty, value)
}
08 }
09 }
You need to create a dependency property named TitleProperty that allows developers to set the Title.
You also need to ensure that the default value of the TitleProperty dependency property is set to Untitled.
Which code segment you add at line 03?
A. public static readonly DependencyProperty TitleProperty =
DependencyProperty.Register("Untitled",
typeof(string),
typeof(MyControl),
null)
B. public static readonly DependencyProperty TitleProperty =
DependencyProperty.Register("Untitled",
typeof(string),
typeof(MyControl),
new PropertyMetadata("Title"))
C. public static readonly DependencyProperty TitleProperty =
DependencyProperty.Register("Title",
typeof(string),
typeof(MyControl),
new PropertyMetadata("Untitled"))
D. public static readonly DependencyProperty TitleProperty =
DependencyProperty.Register("Title",
typeof(string),
typeof(MyControl),
new PropertyMetadata(new PropertyChangedCallback((depObj, args) =>
{
depObj.SetValue(MyControl.TitleProperty, "Untitled")
})))
Answer: C

Microsoft   070-506   070-506
14.You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4.
You create a control named MyControl in the application. Each instance of the control contains a list of
FrameworkElement objects.
You add the following code segment. (Line numbers are included for reference only.)
01 public class MyControl : Control
02 {
03
04 public List<FrameworkElement> ChildElements
05 {
06 get {
07 return List<FrameworkElement>)GetValue(MyControl.ChildElementsProperty)
08 }
09 }
10
11 public MyControl()
12 {
13
14 }
15 static MyControl()
16 {
17
18 }
19 }
You need to create the ChildElementsProperty dependency property. You also need to initialize the
property by using an empty list of FrameworkElement objects.
Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.)
A. Add the following code segment at line 03.
public static readonly DependencyProperty ChildElementsProperty =
DependencyProperty.Register("ChildElements", typeof(List<FrameworkElement>), typeof(MyControl),
new PropertyMetadata(new List<FrameworkElement>()))
B. Add the following code segment at line 03.
public static readonly DependencyProperty ChildElementsProperty =
DependencyProperty.Register("ChildElements", typeof(List<FrameworkElement>), typeof(MyControl),
new PropertyMetadata(null))
C. Add the following code segment at line 13.
SetValue(MyControl.ChildElementsProperty, new List<FrameworkElement>())
D. Add the following code segment at line 17.
ChildElementsProperty =
DependencyProperty.Register("ChildElements", typeof(List<FrameworkElement>), typeof(MyControl),
new PropertyMetadata(new List<FrameworkElement>()))
Answer: B, C

Microsoft過去問   070-506   070-506参考書   070-506   070-506
15.You are developing an application by using Silverlight 4 and Microsoft.NET Framework 4.
You add the following code segment. (Line numbers are included for reference only.)
01 var outerCanvas = new Canvas()
02 var innerCanvas = new Canvas()
03 innerCanvas.Width = 200
04 innerCanvas.Height = 200
05 outerCanvas.Children.Add(innerCanvas)
06
You need to set the distance between the left of the innerCanvas element and the left of the outerCanvas
element to 150 pixels.
Which code segment should you add at line 06?
A. outerCanvas.Margin = new Thickness(0.0, 150.0, 0.0, 0.0)
B. innerCanvas.Margin = new Thickness(0.0, 150.0, 0.0, 0.0)
C. outerCanvas.SetValue(Canvas.LeftProperty, 150.0)
D. innerCanvas.SetValue(Canvas.LeftProperty, 150.0)
Answer: D

Microsoft練習問題   070-506   070-506認定証   070-506   070-506参考書   070-506認定資格
16.You are developing a Silverlight 4 application. The application contains a Product class that has a
public Boolean property named IsAvailable.
You need to create a value converter that binds data to the Visibility property of a Button control.
Which code segment should you use?
A. public class BoolToVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo
culture)
{
bool result = System.Convert.ToBoolean(parameter)
return result Visibility.Visible : Visibility.Collapsed
}
public object ConvertBack(object value, Type targetType, object parameter,
System.Globalization.CultureInfo culture)
{
throw new NotImplementedException()
}
}
B. public class BoolToVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo
culture)
{
bool result = System.Convert.ToBoolean(value)
return result Visibility.Visible : Visibility.Collapsed
}
public object ConvertBack(object value, Type targetType, object parameter,
System.Globalization.CultureInfo culture)
{
throw new NotImplementedException()
}
}
C. public class BoolToVisibilityConverter : PropertyPathConverter
{
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo
culture)
{
return this.ConvertTo(value, typeof(Visibility))
}
public object ConvertBack(object value, Type targetType, object parameter,
System.Globalization.CultureInfo culture)
{
throw new NotImplementedException()
}
}
D. public class BoolToVisibilityConverter
{
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo
culture)
{
bool result = System.Convert.ToBoolean(value)
return result Visibility. Visible : Visibility. Collapsed
}
public object ConvertBack(object value, Type targetType, object parameter,
System.Globalization.CultureInfo culture)
{
throw new NotImplementedException()
}
}
Answer: B

Microsoft過去問   070-506認証試験   070-506   070-506認定資格
17.You are developing a Silverlight 4 application. The application contains a Product class that has a
public string property named Name.
You create a TextBox control by using the following XAML fragment.
<TextBox Text="{Binding Name, ValidatesOnDataErrors=True}" />
You need to ensure that validation errors are reported to the user interface. You also need to ensure that
a validation error will occur when the TextBox control is empty.
Which code segment should you use?
A. public class Product
{
[Required()]
public string Name { get
set
}
}
B. public class Product : IDataErrorInfo
{
public string Name { get
set
}
public string Error { get { return null
} }
public string this[string columnName]
{
get
{
if (columnName == "Name" && string.IsNullOrEmpty(Name))
{
throw new ValidationException("Name should not be empty!")
}
return string.Empty
}
}
}
C. public class Product : IDataErrorInfo
{
public string Name { get
set
}
public string Error { get { return null
} }
public string this[string columnName]
{
get
{
if (columnName == "Name" && string.IsNullOrEmpty(Name))
{
return "Name should not be empty!"
}
return string.Empty
}
}
}
D. public class Product
{
private string _name
public string Name
{
get { return _name
}
set
{
if (string.IsNullOrEmpty(value))
throw new ValidationException("Name should not be empty!")
_name = value
}
}
}
Answer: C

Microsoft   070-506   070-506   070-506
18.You are developing a ticketing application by using Silverlight 4. You have a listbox named lstTickets
that contains a list of the tickets. The page contains a button that allows the user to print the tickets. The
PrintView UserControl binds to the type in lstTickets and is designed to fit a standard sheet of paper.
You add the following code segment to the button event handler. (Line numbers are included for
reference only.)
01 var doc = new PrintDocument()
02 var view = new PrintView()
03 doc.PrintPage += (s, args) =>
04 {
05 var ppc = doc.PrintedPageCount
06 if (ppc < lstTickets.Items.Count)
07 {
08 var data = lstTickets.Items[ppc]
09 view.DataContext = data
10 args.PageVisual = view
11
12
13 }
14 }
15 doc.Print("tickets")
You need to use the Silverlight printing API to print each ticket on its own page. You also need to ensure
that all tickets in the listbox are printed.
Which code segment should you insert at lines 11 and 12?
A. if (args.HasMorePages == false)
return
B. if (args.HasMorePages == true)
return
C. if (doc.PrintedPageCount < this.lstTickets.Items.Count 1)
args.HasMorePages = true
D. if (ppc == this.lstTickets.Items.Count 1)
doc.EndPrint += (o, p) => { return
}
Answer: C

Microsoft   070-506過去問   070-506認証試験   070-506認定試験
19.You are developing an outofbrowser
application by using Silverlight 4.
The main page of the application contains the following code segment.
public MainPage()
{
InitializeComponent()
NetworkChange.NetworkAddressChanged += (s, e) => CheckNetworkStatusAndRaiseToast()
CheckNetworkStatusAndRaiseToast()
}
You need to ensure that the application will raise a toast notification when network connectivity changes.
Which two actions should you perform in the CheckNetworkStatusAndRaiseToast method? (Each correct
answer presents part of the solution. Choose two.)
A. Verify that App.Current.IsRunningOutOfBrowser is true.
B. Verify that App.Current.IsRunningOutOfBrowser is false.
C. Verify that App.Current.HasElevatedPermissions is true.
D. Verify that App.Current.HasElevatedPermissions is false.
E. Examine NetworkInterface.GetIsNetworkAvailable().
F. Call App.Current.CheckAndDownloadUpdateAsync() in a try/catch block.
Answer: A, E

Microsoft練習問題   070-506   070-506   070-506

NO.20 You are developing a Silverlight 4 application.
The application defines the following three event handlers. (Line numbers are included for reference
only.)
01 private void HandleCheck(object sender, RoutedEventArgs e)
02 {
03 MessageBox.Show("Checked")
04 }
05
06 private void HandleUnchecked(object sender, RoutedEventArgs e)
07 {
08 MessageBox.Show("Unchecked")
09 }
10
11 private void HandleThirdState(object sender, RoutedEventArgs e)
12 {
13 MessageBox.Show("Indeterminate")
14 }
You need to allow a check box that can be selected, cleared, or set to Indeterminate. You also need to
ensure that the event handlers are invoked when the user changes the state of the control.
Which XAML fragment should you use?
A. <CheckBox x:Name="cb2" Content="Three State CheckBox"
IsChecked="True" Checked="HandleCheck"
Indeterminate="HandleUnchecked" Unchecked="HandleUnchecked" />
B. <CheckBox x:Name="cb2" Content="Three State CheckBox"
IsThreeState="True" Checked="HandleCheck"
Indeterminate="HandleThirdState" Unchecked="HandleUnchecked" />
C. <CheckBox x:Name="cb2" Content="Three State CheckBox"
IsHitTestVisible="True" Checked="HandleCheck"
Indeterminate="HandleThirdState" Unchecked="HandleUnchecked" />
D. <CheckBox x:Name="cb2" Content="Three State CheckBox"
IsEnabled="True" Checked="HandleCheck"
Indeterminate="HandleUnchecked" Unchecked="HandleUnchecked" />
Answer: B

Microsoft認定資格   070-506   070-506過去問   070-506

JapanCertは最新の00M-653問題集と高品質のHP0-J62問題と回答を提供します。JapanCertのHP2-B103 VCEテストエンジンと000-656試験ガイドはあなたが一回で試験に合格するのを助けることができます。高品質のC-TSCM62-64 PDFトレーニング教材は、あなたがより迅速かつ簡単に試験に合格することを100%保証します。試験に合格して認証資格を取るのはそのような簡単なことです。

記事のリンク:http://www.japancert.com/070-506.html

没有评论:

发表评论