Some ships you can book them on-line. On all the others you can fill out the form and turn it in as soon as you step on the ship. If you know what you want to do, then go ahead and fill out the form early. You can always change it later as long as you go on another excursion. However, you can't just cancel without signing up for something else. If you do so, then you'll loose the money you've already paid.
On the Glory you can book thru the interactive TV in your room as soon as you board. You or your TA can get a list of excursions faxed from Carnival so you can plan in advance. I also would strongly recommened booking online direct and bypass the ship. We haven't booked a ship excursion in years, too crowded and too expensive for the exact same thing you can book yourself.
As this is the Carnival board I can answer for Carnival...you can book as soon as you get onboard. Online booking is in the works and was supposed to be operational this summer but there have been unexpected glitches in the system so for now, you must wait until you get on the ship.