It sounds like what you want to do is to go sightseeing around your code, but be able to easily return to where you started.
If you do your sightseeing with PageUp / PageDown / the scroll bar / the mouse scroll wheel / etc., then the text cursor stays where you left it, so all you need to do is to hit the left or right arrow key, which will move the cursor in the line it is in and scroll the document to bring that line back into view.
If you actually want to do something that moves the text cursor somewhere else in the document, and then return to where you were, try using the Set Jump Point / Previous Jump Point / Next Jump Point commands from the Go menu (and of course, if you end up using these much, you can always assign key commands to them).
Regards,
Neil Faiman