2

We have some partial views which need to be used in several MVC projects. Has anyone done this successfully?

Could Areas in MVC 2 be of any use ? Could a sub area project use a partial view from the parent project or the other way around?

Thank you !

Steve Ward
  • 1,207
  • 3
  • 16
  • 42
  • Possible duplicate of: http://stackoverflow.com/questions/5239361/is-it-possible-to-reuse-partial-views-on-multiple-projects-in-asp-net-mvc – Ashfaq Hussain Oct 16 '12 at 11:54

2 Answers2

1

AFAIK Areas is for separating One Project to different sections.

ali62b
  • 5,363
  • 4
  • 22
  • 25
1

I would consider creating either a separate library — not ideal for isolating UI logic — or a code template — very much like other Visual Studio components, e.g. starter kits, do it. In this case, you can encapsulate reusable UI components across projects.

Pops
  • 30,199
  • 37
  • 136
  • 151
Vlad
  • 3,866
  • 1
  • 24
  • 20