|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Best practice for sharing code between ASP and Winforms apps?Hi all,
I've got a situation where I need to create a Windows Forms application as an admin tool which is driven by the same data as an ASP.NET application. Luckily my 3-tier-ish design means my data and business objects will cope quite well with this, but I'm wondering what the best way to do this is? I'm not sure I want both apps in the same folder, but I want some of my classes shared between the apps. Can anyone who's done this comment? Any articles I should read? Cheers, JC Just put your business assemblies into the app folders of both applications.
-- Show quoteHTH, Kevin Spencer Microsoft MVP Professional Chicken Salad Alchemist A lifetime is made up of Lots of short moments. "JDC" <jeremy.d.coll***@gmail.com> wrote in message news:1149698649.684690.290940@f6g2000cwb.googlegroups.com... > Hi all, > > I've got a situation where I need to create a Windows Forms application > as an admin tool which is driven by the same data as an ASP.NET > application. > > Luckily my 3-tier-ish design means my data and business objects will > cope quite well with this, but I'm wondering what the best way to do > this is? > > I'm not sure I want both apps in the same folder, but I want some of my > classes shared between the apps. > > Can anyone who's done this comment? Any articles I should read? > > Cheers, JC > OK, let me check if I've got this right. I add a new class library
project to my web application solution, and move my shared classes into that .dll project. Then I reference that .dll in my Windows Forms app? Kevin Spencer wrote: Show quote > Just put your business assemblies into the app folders of both applications. > > -- > HTH, > > Kevin Spencer > Microsoft MVP > Professional Chicken Salad Alchemist > > A lifetime is made up of > Lots of short moments. > > "JDC" <jeremy.d.coll***@gmail.com> wrote in message > news:1149698649.684690.290940@f6g2000cwb.googlegroups.com... > > Hi all, > > > > I've got a situation where I need to create a Windows Forms application > > as an admin tool which is driven by the same data as an ASP.NET > > application. > > > > Luckily my 3-tier-ish design means my data and business objects will > > cope quite well with this, but I'm wondering what the best way to do > > this is? > > > > I'm not sure I want both apps in the same folder, but I want some of my > > classes shared between the apps. > > > > Can anyone who's done this comment? Any articles I should read? > > > > Cheers, JC > > Well, it's better if you include the class library project in the solution.
You can include the same projects in many different solutions. -- Show quoteHTH, Kevin Spencer Microsoft MVP Professional Chicken Salad Alchemist A lifetime is made up of Lots of short moments. "JDC" <jeremy.d.coll***@gmail.com> wrote in message news:1149708562.239975.145220@j55g2000cwa.googlegroups.com... > OK, let me check if I've got this right. I add a new class library > project to my web application solution, and move my shared classes into > that .dll project. Then I reference that .dll in my Windows Forms app? > > > Kevin Spencer wrote: >> Just put your business assemblies into the app folders of both >> applications. >> >> -- >> HTH, >> >> Kevin Spencer >> Microsoft MVP >> Professional Chicken Salad Alchemist >> >> A lifetime is made up of >> Lots of short moments. >> >> "JDC" <jeremy.d.coll***@gmail.com> wrote in message >> news:1149698649.684690.290940@f6g2000cwb.googlegroups.com... >> > Hi all, >> > >> > I've got a situation where I need to create a Windows Forms application >> > as an admin tool which is driven by the same data as an ASP.NET >> > application. >> > >> > Luckily my 3-tier-ish design means my data and business objects will >> > cope quite well with this, but I'm wondering what the best way to do >> > this is? >> > >> > I'm not sure I want both apps in the same folder, but I want some of my >> > classes shared between the apps. >> > >> > Can anyone who's done this comment? Any articles I should read? >> > >> > Cheers, JC >> > > That makes sense. Thanks for the advice.
Kevin Spencer wrote: Show quote > Well, it's better if you include the class library project in the solution. > You can include the same projects in many different solutions. > > -- > HTH, > > Kevin Spencer > Microsoft MVP > Professional Chicken Salad Alchemist > > A lifetime is made up of > Lots of short moments. > > "JDC" <jeremy.d.coll***@gmail.com> wrote in message > news:1149708562.239975.145220@j55g2000cwa.googlegroups.com... > > OK, let me check if I've got this right. I add a new class library > > project to my web application solution, and move my shared classes into > > that .dll project. Then I reference that .dll in my Windows Forms app? > > > > > > Kevin Spencer wrote: > >> Just put your business assemblies into the app folders of both > >> applications. > >> > >> -- > >> HTH, > >> > >> Kevin Spencer > >> Microsoft MVP > >> Professional Chicken Salad Alchemist > >> > >> A lifetime is made up of > >> Lots of short moments. > >> > >> "JDC" <jeremy.d.coll***@gmail.com> wrote in message > >> news:1149698649.684690.290940@f6g2000cwb.googlegroups.com... > >> > Hi all, > >> > > >> > I've got a situation where I need to create a Windows Forms application > >> > as an admin tool which is driven by the same data as an ASP.NET > >> > application. > >> > > >> > Luckily my 3-tier-ish design means my data and business objects will > >> > cope quite well with this, but I'm wondering what the best way to do > >> > this is? > >> > > >> > I'm not sure I want both apps in the same folder, but I want some of my > >> > classes shared between the apps. > >> > > >> > Can anyone who's done this comment? Any articles I should read? > >> > > >> > Cheers, JC > >> > > > Hello JDC,
Mmmmm... The GAC is yummy. -Boo Show quote > Hi all, > > I've got a situation where I need to create a Windows Forms > application as an admin tool which is driven by the same data as an > ASP.NET application. > > Luckily my 3-tier-ish design means my data and business objects will > cope quite well with this, but I'm wondering what the best way to do > this is? > > I'm not sure I want both apps in the same folder, but I want some of > my classes shared between the apps. > > Can anyone who's done this comment? Any articles I should read? > > Cheers, JC > Tasty, perhaps, but a little complex to prepare. I think I'll stick
with the basic xcopy flavour for the time being :-) Cheers, JDC GhostInAK wrote: Show quote > Hello JDC, > > Mmmmm... The GAC is yummy. > > -Boo > > > Hi all, > > > > I've got a situation where I need to create a Windows Forms > > application as an admin tool which is driven by the same data as an > > ASP.NET application. > > > > Luckily my 3-tier-ish design means my data and business objects will > > cope quite well with this, but I'm wondering what the best way to do > > this is? > > > > I'm not sure I want both apps in the same folder, but I want some of > > my classes shared between the apps. > > > > Can anyone who's done this comment? Any articles I should read? > > > > Cheers, JC > > |
|||||||||||||||||||||||