I'm not familiar with Access, so don't know how to get at the column values. But your code would probably include something like the following few lines:
loop through all values....
if abs(CurrentVal-1)<abs(ClosestVal-1) then
ClosestVal=CurrentVal
{if necessary, set pointer to current record here}
end if
.... end loop
Rob