To use the sandstone you must be standing (not riding) and holding a sandstone. The weapon which you wish to mend must be in your inventory and not wielded. Now type 'mend <weapon>' and you will sit down and start to mend your weapon. The roughness of your weapon will determine the amount of time needed to mend it.
Note: 'mend <weapon>' in a room with a weaponsmith will default to the shopkeeper mob mending the weapon instead of the character.