Jayce is pretty flexible. The standard cannon to hammer combo is (starting in cannon) q/e, wr, w/q, land the auto attacks and e. You can do the hypercharged autos before or after hammer form, doesn't really matter. If your matchup is melee and can't gap close you can often start in hammer form, qwe and then turn to range form to finish off.
You probably already know pressing e after q in cannon form gives the opponent less time to react, but if you can't land them accurately it's better to lay the e down and take aim. Also put the acceleration gate as close to you as you can (you can put it on top of yourself and still have your q accelerate through). This gives you the speed boost right off the bat. This also helps in case you realize you don't want to go in (say you see the jungler). If you put your acceleration gate in front of you for your q/e then you wouldn't have gotten the speed boost. This mechanic can be a little tricky at first and isn't worth doing if it affects your aim.