Thin golf shots are caused when the club head hits too high up on the golf ball, towards the top of the ball. To prevent this from happening you initially need to identify exactly what is making you strike the top of the ball.
Check your grip pressure. This is one of the most common reasons for hitting thin golf shots. You should hold the golf club, not squeeze it because when you squeeze with your hands, the muscles in your arms work and when your muscles work they contract or shorten. So even though you have started with the club head on the ground next to the ball, as soon as you squeeze too tightly your muscles in your arms shorten and effectively you pull the club head up away from the ground and this will produce a thin shot. Check how tightly you are holding the club. If you squeeze the club as tightly as you can and we call that a 10, half your pressure to a 5 and then drop one more to a 4. This is how it feels to hold the club rather than squeeze it so work on having this pressure in your hands throughout your golf swing.
Secondly, check your ball position if you were hitting thin shots. If the ball is positioned too far forwards in your stance, the club head will have reached it's lowest point before it gets to the ball and you will be on an upward swing when you then connect with the ball if it is too far forward in your stance. Similarly, if the ball is too far back in your stance, the club head will be descending and not yet have reached it's lowest point when you then connect with the top of the ball, which will again produce a thin shot. So check your ball position. In order to do this correctly, you need to place an alignment pole or club across your toes. Make a right angle with another alignment pole or club to the pole across your toes. For your pitching wedge and 9 iron, the ball should be opposite the middle of your stance. The ball then moves to the left half a ball for each subsequent club, until it is opposite the inside of your left shoe, or left big toe, for your driver.
With the correct hold pressure and correct ball position, if you are still hitting thin shots we need to address your movement during your swing. A major reason that you will experience hitting thin shots is if you have an over the top movement in your golf swing. This means that as you begin your downswing, the club head moves over the top of your hands and forward of your body position when looking from the side. This produces a very high (or steep) club head position that will now drop down vertically towards the ball. This vertical or steep movement in the club head will result in the club head striking the top of the golf ball more often than not and as such you will hit a thin golf shot. In order to check whether this is happening, place a range basket about one inch to the right of the ball, on the far side (the outside) of the target line. If you are making an over the top action, you will hit the basket before the ball because as the club head moves over the top of your hands it will also move to the far side of the target line which is where you have placed the range basket, so you will strike the basket before the ball. If this is the case, work on swinging the club head back towards the ball on the inside of the basket. This will allow the club head to approach the ball on a much gentler (flatter) approach angle and as a result you will connect with the side and bottom of the ball rather than the top.
If you are still thinning shots following this you may be releasing the club early. This simply means that on your downswing you are creating a straight line between your left arm and the club shaft before you connect with the golf club. This straight line should not happen until you connect with the ball and if it occurs too early before impact, the low point for the club head will be reached. If the low point for the club head is reached before you strike you will then catch the ball on your upswing and this will result in you hitting the upper part of the golf ball and producing a thin golf shot.
To encourage you to make a downwards movement towards the ball and to allow you to create correct release, and get the straight left arm and club shaft position where the ball is, try this drill. Place a golf ball or head cover opposite your right foot and on the target line. Make a practice swing and swing down without hitting the head cover, working on striking the ground to the left of it where the ball would be. Once you are successfully achieving this, put a golf ball in and try to do the same thing. Swing down without hitting the head cover, but strike the ground just to the left of it where the ball is.
This should get you hitting much sweeter, more solid golf shots that will improve your connection and strike, increase your distance and get you enjoying playing your golf shots again.