Getting to Moffat
While getting to Moffat by public transport takes some care, it really is worth the planning and the effort. Moffat lost its railway branch line some years ago and is now dependent on bus connections. Nevertheless, the West Coast Mainline still runs near it, even if the nearest station is Lockerbie. And there is the A74(M) for those endowed with a motor car.
Speaking of Lockerbie, the obvious thing to do is to get the train there when travelling to Moffat. However, the connecting bus (Stagecoach 382) to Moffat is not as regular as it might be. Another option is to get to Dumfries and catch a bus from there: these are more frequent.
However, getting to Dumfries is then the trick to accomplish. There are train services there from Carlisle, but there is an air of irregularity about them. There is, however, a regular bus service (Stagecoach Cumbria 79) between Carlisle and Dumfries with a journey time of up to 90 minutes. From the north, there are somewhat infrequent services from Glasgow (Stagecoach Western X74) and Edinburgh (coach services 101 and 102).
For information, Dumfries and Galloway Council is a good port of call for public transport information, particularly timetables. Stagecoach Western Scotland is the major bus operator in the area, while smaller operators like McEwan's Coach Services abound as well. Stagecoach Cumbria operates services from Carlisle into the region. And DGC operates social services itself as well. ScotRail and Virgin Trains are the rail operators in the region.
Now, I have added links to bus timetable information to the above.