Olete.in
Articles
Mock Tests
đź§Ş WPF MCQ Quiz Hub
WPF Mcq Question Set 1
Choose a topic to test your knowledge and improve your WPF skills
1. The TextBox control shows a default context menu with options to Cut, Copy and Paste. Can we override this context menu by defining our own in the TextBox control?
True
False
all of the above
None of the mentioned
2. Can we store the ContextMenu in Resource so that we can reuse it for various control on a form?
True
False
all of the above
None of the mentioned
3. In WPF Padding controls how much extra space gets placed around the inside edges of the element.
True
False
all of the above
None of the mentioned
4. Visibility (defined on UIElement) might sound like a strange property to talk about in the context of layout, but it is indeed relevant. An element’s Visibility property actually isn’t Boolean, but rather a three-state System.Windows.Visibility enumeration. One of Its value is “Collapsed” What is the meaning of this value
The element is invisible yet still participates in layout.
The element is invisible and does not participate in layout
The element gets rendered and participates in layout.
none of the above
5. BAML can’t be decompiled back into XAML
True
False
all of the above
None of the mentioned
6. the .NET Framework 4.0 introduces a handful of new features for the XAML language. This second generation of the XAML language is referred to as
XAML2006
XAML2008
XAML2009
None of these
7. FrameworkElement is derived from
UIElement
ContentControl
Application
Control Box property
8. WPF separates the appearance of an user interface from its behavior. The appearance is generally specified in the_______.
HTML
XAML
XML
XSLT
9. Which of the following layout is not available in WPF?
StackPanel
Canvas
Grid
Table
10. Static and data binding markup extensions are same.True or false?
True
False
all of the above
None of the mentioned
11. WPF is a replacement to DirectX.True or False?
True
False
all of the above
None of the mentioned
12. which is dependency property in this code:
Width
Canvas.Left
Canvas
None of above
13. Transformations are available in which namespace?
System.Windows.UIElement
System.Windows.FrameworkElement
System.Windows.Media
None of above
14. Which tool(s)is/are used to develop WPF applications?
Visual Studio
Expression Blend
Both a & b
Only a
15. WrapPanel Class comes under_______ assembly.
PresentationCore
PresentationFramework
milcore
None of above
16. Development is more efficient because designers can implement an application’s appearance simultaneously with developers who are implementing the application’s behavior.True or false?
True
False
all of the above
None of the mentioned
17. A key element of the Trustworthy Computing initiative in WPF is_______.
XAML
SDL
XAP
None of above
18. Which of the following is routing strategy of Routed events?
Bubbling
Direct
Tunneling
All of above
19. Child controls are virtualized and arranged on a single line that is either horizontally or vertically oriented. Is true about?
DockPanel
VirtualizingStackPanel
WrapPanel
StackPanel
20. Child controls are positioned in left-to-right order and wrapped to the next line when there are more controls on the current line than space allows.Is true about?
WrapPanel
StackPanel
VirtualizingStackPanel
DockPanel
21. .In DockPanel Child controls are aligned to the edges of the panel.True or False?>
True
False
all of the above
None of the mentioned
22. Which of the following is not WPF model(used to create a new control/custom control)?
User Control Model
Control Model
Framework Element Model
Element Model
23. .One of the primary architectural philosophies used in building WPF was a preference for properties over methods or events.
True
False
all of the above
None of the mentioned
24. .Which of the following class is used to implement Trees in WPF?
LogicalTreeHelper
VisualTreeHelper
AbstractTreeHelper
a & b
25. ____class provides the GetChildren, GetParent, and FindLogicalNode methods for logical tree traversal.
LogicalTreeHelper
VisualTreeHelper
AbstractTreeHelper
A & B
26. ___ is a DependencyProperty instance, which is obtained as a return value when registering a dependency property, and then stored as a static member of a class.
Dependency property
Dependency property identifier
CLR “wrapper”
None of above
27. Windows Presentation Foundation (WPF) introduces _______ events that can invoke handlers that exist on various listeners in the element tree of an application.
routed
bubbled
child
None of above
28. The________attribute works for FrameworkElement and FrameworkContentElement used for consistency.
Class
Name
Key
Value
29. All XAML resources should have an________attribute in WPF.
x:Name
x:Class
x:Value
x:Key
30. x:Null specifies null as a value for a property and can be used either for attributes or property element values.True or False?
True
False
all of the above
None of the mentioned
31. _____provides a value for a property by deferring that value to be a run-time reference to a resource.
StaticResource
DynamicResource
RelativeSource
Binding
32. _______provides a value for a property by substituting the value of an already defined resource.
StaticResource
DynamicResource
RelativeSource
Binding
33. ____provides source information for a Binding that can navigate several possible relationships in the run-time object tree.
StaticResource
DynamicResource
RelativeSource
Binding
34. ____provides a data bound value for a property, using the data context that applies to the parent object at run time.
StaticResource
DynamicResource
RelativeSource
Binding
35. What is full form of WPF?
Windows Presentation FoundationClass
Windows Precomputed FoundationClass
Windows Presentation Functions
None of these
36. What is XAML?
Extensible and Markup Language
Extensible Application Markup Language
Xtra Application Markup Language
None of these
37. Does that mean WPF has replaced DirectX?
Yes
no
all of the above
None of the mentioned
38. Is XAML meant only for WPF ?
Yes
no
all of the above
None of the mentioned
39. What is the stand for is XBAP?
extensible based application
XAML Browser Application
XAML Based Application
None of the mentioned
40. Which of the following have two states of Freezable object?
Fix and Unfix
Frozen and unfrozen.
Static and Dynamic
none of the mentioned
41. Which layout control would be the best choice for a user interface that requires evenly spaced controls laid out?
Grid
Canvas
UniformGrid
EvenlyGrid
42. Events Supported by WPF is are?
Direct Event
Bubbling Event
Tunneling Event
All of the above
43. WPF transformations can be used for
Only rotaion
Only scaling
Only skewing
rotation, scaling, and skewing
44. Which object can be used share the variable across pages in WPF?
Application
Session
Cookies
ViewState
45. Which of the following is true regarding XAML?
Separation of designer code and logic
Tools like Expression Blend do not support XAML.
XAML is platform independent.
All of the above
46. How you can set a working mnemonic key for a label?
Set the Target property to the target control. Precede the letter for the mnemonic key with an underscore symbol in the Content property of the Label control.
You must place both the Label control and the Target property in the same container.
Set the Mnemonic Key property on the Label control.
None of the mentioned
47. In WPF which language is used to express user interface?
XML
XAML C. WSDL
WSDL
C#
48. WPF stands for - Windows Presentation Foundation.
True
False
all of the above
None of the mentioned
49. _____ layout isn't available in WPF.
StackPanel
Table
Canvas
All of the above
50. WPF is a replacement to
IndirectX
DirectX
Both 1 and 2
none of the above
Submit