S
steven scaife
Hello, I am in need of some guidance
I am creating an app where I can create forms through a wizard. these forms
are then saved to the database and i have a class that builds the forms I
have generic handlers for some controls such as a fileupload or picture file
upload. So when the form is constructed I attach the event handler to these
controls.
Basically this allows me to create forms quickly and easily and there is no
problem if the form just saves to a database. However I want to put business
logic in a dll for each project I create. for instance when the form is saved
I may have to run some specific logic or I may have a hyperlink that when
clicked adds another textbox to the form e.g. adding extra textboxes for
names in a event registration form.
My issue is I am not sure of the best way to go about doing this.
What i am thinking is that when the form is created I have another step in
my wizard that allows me to view the methods in the dll via reflection and
save the method name and assembly name to the database. Then when the form is
created I can then use reflection to add the method to the controls event.
Is this the best way to go about doing this, should I create a set of
interfaces that the classes must inherit from for doing specific things, is
there a better way of doing what I want to do.
Colde samples are appreciated if applicable but I would prefer links to some
good resources and advice
I am creating an app where I can create forms through a wizard. these forms
are then saved to the database and i have a class that builds the forms I
have generic handlers for some controls such as a fileupload or picture file
upload. So when the form is constructed I attach the event handler to these
controls.
Basically this allows me to create forms quickly and easily and there is no
problem if the form just saves to a database. However I want to put business
logic in a dll for each project I create. for instance when the form is saved
I may have to run some specific logic or I may have a hyperlink that when
clicked adds another textbox to the form e.g. adding extra textboxes for
names in a event registration form.
My issue is I am not sure of the best way to go about doing this.
What i am thinking is that when the form is created I have another step in
my wizard that allows me to view the methods in the dll via reflection and
save the method name and assembly name to the database. Then when the form is
created I can then use reflection to add the method to the controls event.
Is this the best way to go about doing this, should I create a set of
interfaces that the classes must inherit from for doing specific things, is
there a better way of doing what I want to do.
Colde samples are appreciated if applicable but I would prefer links to some
good resources and advice