Disclosed herein are an electronic device and method. The electronic device includes a display, and a processor. The process may execute the method, which includes detecting, when the electronic device is moved from a first position to a second position, path information corresponding to a sequence of location changes according to movement of the electronic device from the first position to the second position, and controlling the display of the electronic device to display guide information including a generated path from the second position to the first position utilizing the detected path information.