Can someone point me in the right direction on building a form that users will register, make a payment, confirmation email with print out and a way the data can be exported into a .csv file?

The form is probably the easier part but how would we export the data from a GUI?

THanks