Values proc functionality complete and tested

I think the approach is now much tidier, sorry it took a little while to get wrapped up