40+ WPF Interview Questions

40+ WPF Interview Questions

WPF Interview Questions

1) What is WPF? 

WPF represents Window Presentation Framework. It is the most recent introduction API by Microsoft Windows. WPF is a 2D and 3D designs motor.

2) What are the abilities of WPF? 

WPF has following abilities:

It has all the equal basic client controls like catches, checkboxes, sliders and so on.

It has every one of the capacities of HTML and Flash.

It bolsters fix and stream position report.

It gives the office of information official, activity and sight and sound.

3) What are assets in WPF? 

In WPF, assets are utilized to give a basic method to reuse normally characterized items and qualities. They likewise encourage you to set the properties of various controls at once. For instance, you can set the foundation property on a few components in a WPF application utilizing a solitary asset.

4) What is XAML? 

XAML is an explanatory XML based language. It encourages you to characterize articles and properties in XML. Its records are stacked by XAML parser.

5) What is the utilization of XAML? 

XAML is utilized to portray the articles, properties and their connection in the middle of them. It makes you ready to make any kind of articles for example graphical and non-graphical.

6) What is a directed occasion? 

There are numerous sorts of components in a commonplace WPF application and these components are set in a component tree relationship. A steered occasion is a sort of occasion that is utilized to conjure handlers on numerous audience members in a component tree.

7) what number sorts of records are bolstered by WPF? 

Two kinds of archives are upheld by WPF.

Stream group archive: Flow position report is utilized to change the substance to fit on the screen estimate.

Fixed arrangement record: Fixed configuration archive present substance independent of the screen estimate.

8) What do you know by substance arrangement in WPF? 

There are two sorts of substance arrangement in WPF:

HorizontalContentAlignment

VerticalContentAlignment

These the two properties are characterized in the System.Windows.Controls.Control class which is the parent class of all controls in WPF.

As a matter of course the vertical and level arrangement of substance of a TextBox is left and top and catch is focus.

For instance:

Meeting Wpf 1

9) Write down the linguistic structure for assets in WPF. 

Linguistic structure:



<!- Content - >


Here,

elementName: Name of the component that utilizes the asset.

propertyName: Name of the property that takes its incentive from the asset.

markupExtension: Define sort of asset.

keyName: key name of the asset, which is one of a kind string to recognize the asset.

10) what number sorts of assets accessible in WPF? 

There are essentially two sorts of assets in WPF:

Static Resource

Dynamic Resource

11) Which namespace is required for working with 3D? 

System.Windows.Media.Medi3D is the namespace required for working with 3D.

12) Can we say that WPF is the substitution of DirectX? 

No, WPF can't supplant DirectX, in light of the fact that WPF isn't sufficient proficient to make diversions with shocking illustrations. WPF is just intended to be a substitution of windows frames, not DirectX.

13) What are the reliance properties? 

Reliance properties are the sort of properties which have a place with a particular class yet can be utilized for another class.

14) What is CLR? 

CLR represents Common Language Runtime. It is a run time condition for .NET

15) What are the freezable items in WPF? 

An article which is unchangeable is known as freezable item. The freezable articles perform better and furthermore more secure in the event that they are required to be shared between strings.

16) What is esteem converter in WPF? 

An esteem converter goes about as an extension between an objective and a source and it is important when an objective is bound with one source, for example you have a content box and a catch control. You need to empower or handicap the catch control when the content of the content box is filled or invalid. For this situation you have to change over the string information to Boolean. This is conceivable utilizing a Value Converter. To actualize Value Converters, there is the necessity to acquire from I Value Converter in the System.Windows.Data namespace and execute the two strategies Convert and Convert Back.

17) What is the contrast among Silverlight and WPF program application? 

These are the principle contrasts between the Silverlight and WPF program application:

.NET structure is required for running WPF program application on the customer machine while Silverlight runs utilizing just module.

The applications made in WPF rely upon the working framework since .NET structure just keeps running on Windows. Then again, Silverlight modules can be introduced on those OS additionally, which are not Windows.

18) Which device is required to draw a counterfeit of your WPF application? 

The SketchFlow device is utilized to draw a fake of WPF application.

19) What are the distinctive sorts of format controls? 

Following are the distinctive kinds of format controls:

Framework

DockPanel

WrapPanel

Canvas

UniformGrid

StackPanel

20) What is PRISM? 

Crystal is a system that is utilized for making complex applications for WPF, Silverlight or Window telephones. It utilizes MVVM, IC, Command Pattern, DI and detachment of worries to get free coupling.

21) What is CustomControl? 

CustomControl is utilized to grow the elements of existing controls. It contains a default style in subject and code document.

22) What is the utilization of custom control? 

Custom control is the most ideal approach to make a control library. It can likewise be styled or format.

23) What is the Path activity in WPF? 

Way activity is an alternate sort of movement. In this activity, the energized articles pursue a way set by the way geometry.

24) What is the significance of BAML in WPF? 

BAML represents Binary Application Markup Language. It is a sort of XAML that has been tokenized, parsed, and changed into double structure.

25) What is the contrast among XAML and BAML? 

The main contrast among XAML and BAML is that BAML is a packed definitive language which is stacked and parsed faster than XAML.

26) What is the contrast between Page control and Window Control in WPF? 

No.

Page controls

Window controls

1. Page controls direct the facilitated programs applications.

Window controls manage windows application.

2. Page controls can't contain window control.

Window controls may contain page control.

27) What is the parent class of control class of WPF? 

The control class of WPF is gotten from FrameworkElement.

28) What is the contrast among DynamicResource and StaticResource? 

StaticResource

DynamicResource

StaticResources assess the asset one time as it were.

DynamicResource assesses the assets each time they are required.

StaticResource is light.

DynamicResource is substantial due to every now and again assessed.

29) Is MDI upheld in WPF? 

MDI isn't upheld in WPF. A similar usefulness of MDI can be given by UserControl.

30) What is serialization? 

Serialization is a procedure of changing over the condition of an item to stream of bytes.

31) What is MVVM? 

MVVM is represent Model View ViewModel. It is a system for making applications in WPF. MVVM is equivalent to the MVC structure. It is a 3-level engineering in addition to one more layer. Free coupling can be achieved by utilizing MVVM.

32) When did MVVM presented? 

MVVM was presented by John Gossman in 2005. It was acquainted explicitly with use with WPF as a solid utilization of Martin Fowler's more extensive Presentation Model example.

33) What are the benefits of MVVM? 

MVVM has the accompanying favorable circumstances:

Particularity

Test driven methodology.

Division UI and Business layer as view and view display.

Code sharing among pages and structures.

Simple to Maintain.

34) What are the most imperative highlights of MVVM? 

A rundown of most imperative highlights of MVVM:

MVVM isolates the business and introduction layers, similar to MVP and MVC.

It improves Structure/detachment of concerns (View, ViewModel and Model).

It empowers a superior Design/Developer Workflow.

It improves effortlessness and testability.

It is empowered by the vigorous information restricting ability of XAML.

No compelling reason to utilize a code behind record (moderate code-behind document).

Gives application improvement capacity to various situations.

Incredible Data Binding, order, approval and significantly more.

The planner and designer can cooperate.

35) How is MVVM not quite the same as MVC? 

MVC represents Model-View Controller and.MVVM represents Model-View ViewModel.

In MVVM, View Model is utilized rather than a controller. This View Model is available underneath the UI layer. It uncovers the order items and information that the view requires. It acts like a holder object from which see gets its activities and information.