In this lecture we are going to carry on from where we left off in part 1 we are going to add another
component an important component.
This was known as a picture box.
This is where the actual drawing will take place.
So in your tool box click on common controls and there should be one for a picture box.
Just drag it and drop it in.
While the picture box is highlighted we want to change some of the properties.
So when you change properties always make sure that the property you are changing for the component
is the right one.
As you can see mine I can tell is the actual picture box because the name shows up.
So what are the moment I want to resize that so that so that it fills the screen just above this menu
item here.
All right.
So to do that I need to change a property that is the property or board for going to the layout part
of it.
I need to docket this a dock property at the moment it is set to announce I need to change that and
set it to fill and that will fill the entire screen.
So it takes up the screen but not you know not the menu strip and not the tool strip.
I want to change the background color.
Want to change it to black.
So looking at properties is an option called bad color.
Click on that and click on the dropdown and go web and click on black.
So we've now got the background color for.
So this is where the actual drawing will take place.
The picture box really is designed to display pictures but we want to use it for something else.
We want to be able to draw on it if you want to find out more information by the picture box.
Why you've got it selected.
Just hit F1 on your keyboard and that will take you to the Microsoft site where you can read up more
about it.
So the main purpose of it is to use it to display pictures what we want we're going to use it for something
else.
When to use it to draw.
So he's going to act as we're going to use it to act as a canvas where we can draw on the way we are
going to achieve this is to we have to create an image in real time that can be displayed in the picture
box component.
The way round that is to use a bitmap image format what we'll do we'll have to draw on draw the image
on the bitmap which will then display in the picture box.
So we're gonna try and achieve this using code.
So in the next lecture we'll start writing the piece of code to put these together.
Thanks very much for watching.
Take care.
Bye for now.