WPF Getting Started | Magnificent | C# WPF Tutorial

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
in this video we are going to see WPF Windows presentation foundation so WPF Windows presentation Foundation the application which we are going to develop that will that are going to run on the Windows platform so what are the prerequisites required to develop these applications first of all to develop any kind of application we required some environment so this environment we are going to use a visual studio so I mentioned as a latest version of Visual Studio 2022 and this WPF will have a UI screen graphical user inter screen and how that is going to develop so here we are going to develop this into the saml we are going to develop UI graphical user interface using a zaml and backend coding using a cam so these are the three prerequisite required so this is the environment which we are going to use and this is for the UI to uh to graphical to develop a graphical user interface sample we are going to use and this is for the coding back end coding we are going to use C so this three are the basic things required to develop a WPF applications then what is mean by zaml so zaml is one of the declarative language so once those who are aware about the XML language so it's quite similar to the XML language so extensible if you take the full form of this examl is nothing but extensible application markup language it's a declarative language that is based on the XML only and it is extensively used to build a user interfaces which kind of user interfaces it is used so starting from applications that is WPF apps then uwp universal windows platform and the zamin forms and the back end coding as we mentioned we are going to develop application in the backend coding that is a c c is developed by Microsoft that is going to run on this NET Framework okay so this is objectoriented programming okay it supports objectoriented P okay so this supports to the Ops it's a type language so C by using a c we can develop desktop apps mobile apps and web apps also games we can be developed by using a c language so C language will be useful to write a backend code so now uh let's see how to develop WPF desktop app once we install and open the visual studio and then you will find this is the start page for opening the visual studio then for creating a project so we have to click on this create new project and uh and here we want a language we are going to use a c shop and the platform we are going to develop application for the windows platform and the project type is a desktop application so here you can find the third template which is useful for creating a WPF application WPF application a project for creating a net WPF application so click on the it and click on the next so here we can give a project name ppf app 01 WPF app 01 and solution we are going to give like WPF app app Solutions and we can store we can store this into local directory this is a project okay so I'm saving so I have given the project name as WPF app 01 and I have store I'm going to store this project into D drive magnificent WPF and my solution name is WPF app Solutions click on the next so now uh this is the latest framework of a net which is included in this Visual Studio 2022 click on the create so it will create it will create a default template for us to create to develop a WPF application so now you can see by default two pages has been open first one is a main window. SLE that is extensible application markup language page and this is a backend code main window. xaml.cs so now it's loading it will take little bit time to load it so now you can see by default how much things getting getting created here so you can just pin this one and you can see so in the WPF app Solutions one project which we created that is WPF app01 and the dependencies all net core and this WPF desktop application app. WPF this dependen is got added that is a framewor got added and here by default that is app. s got created in the app. S here is startup URI so when we are going to run this project this main window will be the first thing which is going to run and this will be visible to the user and if you want to write some backend code for this app. if you want to execute something here then we can write it here in this uh paral class of app that is the back end code and now coming to this main window so this is the main window which is going to run when user is running this application okay okay first of all we'll we'll check this first of all we'll check what are the things available here now if you want to if you want to see these two things together then you can click it here one option is there vertical split horizontal split and this is a collapse pin so you can click on this page uh click on this vertical split so it will split and it will be available for us to see both window okay so we can just zoom zoom zoom in zoom out from here so I'll make it small 50% so we can it can be visible for us while changing the details okay so now here here this window window is a default which is get created here and these are the some name spaces so these are this XML NS xmlns all the default name spaces got added and this is our local name space that is nothing but our project name WPF app01 so this title of main window so here is the title of main window so we can change this one my first WPF app so it is it is got updated here and also we can change this height and width let's say make it 550 so it got increased width also we can change let's make it 700 so with also got changed Now by default uh this applic this WP examl will give us a grid so they have declared one grid because this full screen occupied with this gri so inside this window so this window is a root control here we can see is root control or a base control in XML we are calling as you know parent node or root node so here in the zaml is a root element that is a window so inside window we we are going to write all these control so there are two ways directly we can write start writing the control design here if you not aware about the Zam how to write it we can also drag and drop from this toolbox so here are the all these tool boxes are available here so let's say first of all we'll pick this label and we'll just drag from this toolbox and we'll keep it here so label will get create here okay and if I give some name to this label or content to the label hello world so you can see here hello world got created and we can apply multiple properties to it like font size and all let's make it font size 30 it is visible for us let's make it 50 it is getting visible for us all other properties also we can change or here also we can add manually if you know the haml design how it works and if you are beginner we can you can you can add the controls form here itself and if you are uh if you are already worked on these type of application then you also you can add from here here like button control and all let's say I'm adding one button control so so this click me button let's say click me button we are going to add and okay so now this is taking a whole Space so I'll just make this size and all height of this page let's say make it make it 30 30 and width of this page let's make it make it uh 200 so this way we can we can create this click me button and also we can can give additional additional additional properties of this button here let's give the additional properties let's say font size so it will be visible for us so font size make it 30 and this width or height we have to increase like 50 so this way we can add multiple controls into it so this is a label control and this is a but button control what we have added here so this hello world basically for while learning any programming language normally we use to add this hello world so now this save this and uh we can build this WPF one so let's see how it is showing yes now build build is succeed and we can run this application to check how it is showing so now you can check so this is our first WPF applications here we have shown the label hello world and this is a click me button
Info
Channel: Magnificent
Views: 237
Rating: undefined out of 5
Keywords: wpf tutorial c#, wpf, wpf tutorial, xaml tutorial for beginners, c# tutorial, c# wpf, c# wpf tutorial, xaml tutorial, dot net, windows presentation foundation, desktop application development, software engineer
Id: hs2LDNYTbV8
Channel Id: undefined
Length: 8min 49sec (529 seconds)
Published: Sat Dec 09 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.