It's traditional for form action to be processed when the submit button is hit (though some AJAX or web 2.0 -style apps set things in motion earlier and just confirm on button action).
I'm not on a machine with Flash installed just now, but as I recall :
some versions of Flash, if you select the button on the page and then select parameters, you'll see a "click handler" parameter - that would be where you add the web / server address of the script you want to run. If there's no such option visible to you or in your versions, you may have to make your changes in your movie's actionscript.
Then you'll need to be sure that the two buttons, guest book and contacts, have different instance names. You'll have to find the relevant actionscript for each button. The Movie Explorer window might help with that. Then make sure that each button has its own event handler script. The event handler for the button click could be called anything, but you might search first for clickHandler.
http://help.adobe.com/en_US/ActionScript/3.0_UsingComponentsAS3/WS5b3ccc516...