I'm still struggling with understanding OOP so this is a pretty basic question.
I'm not sure if building a custom class for this is necessary or possible. I have a friend that told me, "If you do something over and over, build a class." But I'm not sure in this case if the system.net.mail and database stuff is as good as it gets.
The company I work for does a lot of events. The way I handle it now is to build a registration page that has the form, inserts the registration to the database and then build a report page.
But I have to do this every time there's an event.
The form has name, title, address, etc. Just basic information. There is only one field that comes and goes, the rest of the fields are the same on every registration page. I use code behind to do the parameterized inserts.
So my question is, should I build a class or not? Or does this have to be done for each and every page the way I'm doing it now?