Meriwether, there is a possible pairing - searching Denholm births between 1810 and 1820. (sorry that's a typo - it was 1800 - 1810 I searched)
9 records came up for James Denholm in a search and 3 for William Denholm - these are the only ones that had parents in common. That doesn't necessarily mean they are yours - if your James Denholm was one of the other 8, or even not listed at all..
James Denholm, born or baptised 18.09.1808, Currie, Midlothian
Parents: James Denholm and Margaret Ferguson
Ref: 682/00 0020 0283
William Denholm, born or baptised 24.04.1809, Currie, Midlothian
Parents' James Denholm and Margaret Ferguson
Ref: 682/00 0020 0233
You head your post 'Denholm of Moffatt' and if these 2 are linked then it would appear that James stayed in Midlothian and it's William that moved. No idea if the ages fit with what you have of William? What might help you identify would be anything else you know of William - marriage? Death? If his death was after 1855 you should get some details of his parents so you'd know if your William and the one above could be the same person. Did he appear in the 1851 or 1861 census? If he did it should give you a birth place.
If you want to follow these two entries up up, go to Scotland People and search OPR (Old Parish Records) for births and baptisms - you can look at the originals for 5 credits, and the references for each are given.