2011-06-10 60 views
-1

我有一個程序集並希望在此程序集中使用Web Interface。你將如何實現這一點? IHttpHandler是一種方式,但它非常討厭將html輸出寫入Response。 有沒有更優雅的方式?Howto在組件中實現Web接口

回答

0

你的意思是像embedding views into an assembly

+0

聽起來很有趣,但這不適用於Asp.NET WebForms應用程序,對不對?如果我選擇這種方法,它如何在沒有控制器的情況下工作? – dknaack 2011-06-10 08:55:39

+0

@dknaack,你也可以在這裏看看[MVCContrib Portable areas](http://lostechies.com/erichexter/2009/11/01/asp-net-mvc-portable-areas-via-mvccontrib/)案件。 – 2011-06-10 09:00:08