The name of the ruined castle is Torthorwald Castle. There are lots of pictures on the web when you search the name. Interestingly the wikipedia entry (below) says that the castle is in the center of the village of Torthorwald, this is not correct. It is just on the western edge of the village, about 40 meters from the nearest house. Driving from Dumfries towards Lochmaben, it is very easy to see, being close to the road.
https://en.wikipedia.org/wiki/Torthorwald_Castle
PS Does anyone find the verification questions inflexible? Number when adding f.o.u.r & s.i.x is not ten, number of wheels on a trike is not three…..