Which three code segments should you use in sequence?

DRAG DROP
You are developing a Windows Store app.
The app includes the following event procedure:
Void OnSettingsPaneOpened(SettingsPanesettingsPane,
SettingsPaneCommandsRequestedEventArgseventArga)
You need to call the event procedure when the user opens the settings pane.
Which three code segments should you use in sequence? (To answer, move the appropriate
code segments to the answer area and arrange them in the correct order.)

DRAG DROP
You are developing a Windows Store app.
The app includes the following event procedure:
Void OnSettingsPaneOpened(SettingsPanesettingsPane,
SettingsPaneCommandsRequestedEventArgseventArga)
You need to call the event procedure when the user opens the settings pane.
Which three code segments should you use in sequence? (To answer, move the appropriate
code segments to the answer area and arrange them in the correct order.)

Answer: See the explanation.

Explanation:
Box 1: SettingsPanesp = null;
Box 2: sp = SettingsPane.GetForCurrentView();
Box 3: sp.CommandsRequested += OnSettingsPaneOpened;

Note:
* The SettingsPane class is a static class that enables the app to control the Settings Charm
pane. The app can add or remove commands, receive a notification when the user opens
the pane, or open the pane programmatically.
* The show method displays the Settings Charm pane to the user.
* The GetForCurrentView method gets a SettingsPane object that is associated with the
current app view (that is, with CoreWindow).



Leave a Reply 0

Your email address will not be published. Required fields are marked *