refactoring - Refactor C# Application -
i found this post , second option in first answer
2) if app useful within context of parent apps, being given objects or other arguments other apps, consider refactoring small app allow form's project referenced parent apps. then, parent apps can create new instance of form , display it:
var childform = new smallappform(); childform.owner = this; //the child window close when owner does. childform.show();
i have questions steps have in order accomplish it.
the app trying call can found here.
to change have main (parent) form creates , calls application class, add new project "parent", add main new parent form application. have menu choice start wizard in parent form in order create , call wizard this?
createusercontext context = new createusercontext(); createuserwizard wizard = new createuserwizard(context);
thanks guidance, leslie
what tranform small aplication class library instead of winforms application. (it can project within solution, referenced main project) then, parent application references small application , calls new smallappform()
of course smallappform must public.
class library project type. when create project, can console application, windows form application, class library , many others. should create new project class library type. copy forms of small applications project, make classes public. (there's no program
class in class library, forms , other classes created)
Comments
Post a Comment