Get location without button click