Every time I visit a city, I play a game. I look around and pick an interesting looking high rise out of the skyline, and try to get to the top floor.
Generally, it's a lot more challenging than it sounds. Most high rises have security desks right in the lobby on the ground floor, and you need to be buzzed in. Usually, the best way to get past this is to just ask politely if you can go up to the top floor and take a few pictures of the view. This works best if you have a camera in evidence, some kind of student identification, and a stupid grin on your face. Generally, they let you through.
Another good tactic is to dress business casual and put your earbuds in and walk straight and appear buried in your phone, if you look busy, generally people won't stop you if you walk past their desk, especially right after lunch hour when a lot of people are going back into the building.
If you get stopped, just tell the truth and say you just want to go up and see the view. After that you can pretty much just walk away and they wont care.
If you can get to the elevator, immediately push the highest button, not worth going to a lower floor. If the highest floor is key locked, usually the elevator wont let you push that button. If there are other people on the elevator, and you dont know what floors are locked out, use your judgement on how the other people will react if you push a lot of buttons. Best case scenario is getting an elevator all to yourself. because then all the buttons are yours to command.
If you aren't okay with trying to subvert security for a view, look for fancy hotels. High rise hotels usually put a public bar on the top floor. Checking out the biggest hotels in a city will usually yield a good selection. I personally reccommend The View on top of the Marriot Marquis in San Francisco, and the Top of The Hyatt, at the Hyatt San Diego. The bars on top of big hotels are usually fancy, crowded, and expensive. Get there early, and get a beer. The cocktails aren't the main attraction 40 stories up, so they aren't worth the 15$+ price tag.
Sky high eye spy guys.