Measure the area you want to cover with molding. Measure the length and width using your tape measure. Get molding according to these measurements. However, do make allowances for any wastage or careless cutting and get extra length. You can apply molding to where you ceiling meets the wall or where the wall meets the floor or any surface like cupboards etc.
Apply primer to the molding. Let the first coat dry. Apply another one and let it dry thoroughly. When the primer is all dry, apply a coat of finish pant and wait for it to dry.
Use the Miter saw to cut the one corner of the molding at an angle of 45 degree and the other totally straight to get the perfect alignment. The mitted side will fit well in corners.
Apply construction adhesive to the back surface of the molding using the caulking gun and spread it around.
Hold the molding to the surface you want to install. To keep it in place before the adhesive works, use the painter's tape. Use the caulk gun to apply adhesive around the edges so that the molding sticks well to the surface. Use your fingers to neatly fit in any gaps.
After the molding has set in, finish up with light painting the area so that there are no glitches.