I usually use a small laser. I set it on anything handy. Take a few readings to see how level the floor is and establish my starting point. Then measure down from the arbitrary laser height then transfer that measurement to all the corners and at the end of runs. Then snap a chalk line and screw the ledger to the line tweaking it up or down as needed. Nice and straight and solid with minimal fuss. The ledger also helps provide support to the bottom panel on wide cabinets if you put heavy items in it, opposed to using just leveling feet front and back. You can and some people do, put a leveling foot in the middle for this but its rare from what I have seen.