<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>ASP.NET MVC</title><link>http://forums.asp.net/1146.aspx</link><description>Discussions regarding Model-View-Controller (MVC) support in ASP.NET.  &lt;a href="http://forums.asp.net/1215.aspx"&gt;T4MVC subforum&lt;/a&gt;</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Re: insert PartialView w/ data from aspx page</title><link>http://forums.asp.net/thread/3273633.aspx</link><pubDate>Fri, 03 Jul 2009 14:00:43 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:3273633</guid><dc:creator>currentspulledmeunder</dc:creator><author>currentspulledmeunder</author><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/3273633.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=1146&amp;PostID=3273633</wfw:commentRss><description>&lt;p&gt;I&amp;#39;ve been using entities to get data from my database.&amp;nbsp; Do you know how I can convert them into Models so that I can use the RenderPartial syntax?&amp;nbsp; &lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: insert PartialView w/ data from aspx page</title><link>http://forums.asp.net/thread/3271509.aspx</link><pubDate>Thu, 02 Jul 2009 13:55:35 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:3271509</guid><dc:creator>LandVP</dc:creator><author>LandVP</author><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/3271509.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=1146&amp;PostID=3271509</wfw:commentRss><description>&lt;p&gt;You have to use html.RenderPartial to render your partial view on the page&lt;/p&gt;&lt;pre name="code" class="c-sharp"&gt;&amp;lt;% Html.RenderPartial(&amp;quot;YourViewName&amp;quot;, YourModel); %&amp;gt;&lt;/pre&gt;&lt;p&gt;&lt;br /&gt;And I think that you have to use an action from your main view (that contains your partial view). I.e. do not create the action for your partial view. Instead of it you have to use your main view controller action.&lt;/p&gt;&lt;p&gt;&lt;/p&gt;</description></item><item><title>insert PartialView w/ data from aspx page</title><link>http://forums.asp.net/thread/3270964.aspx</link><pubDate>Thu, 02 Jul 2009 10:13:52 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:3270964</guid><dc:creator>currentspulledmeunder</dc:creator><author>currentspulledmeunder</author><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/3270964.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=1146&amp;PostID=3270964</wfw:commentRss><description>&lt;p&gt;I hope this will be an easy answer but I can&amp;#39;t seem to find it searching.&lt;/p&gt;&lt;p&gt;I have an aspx page with a partial view inside of it.&amp;nbsp; &lt;/p&gt;&lt;p&gt;I am inserting the partial view with the syntax like this:&amp;nbsp; &amp;lt;TagPrefix:TagName ID=&amp;quot;PartialView1&amp;quot; runat=&amp;quot;server&amp;quot;/&amp;gt;&lt;br /&gt;&lt;br /&gt;I get &amp;quot;Object not set to reference errors though, unless I click a link to the data with my controller like this:&lt;br /&gt;&lt;/p&gt;&lt;p&gt;The partial view has a controller that loads data like this:&lt;/p&gt;&lt;p&gt;&lt;pre name="code" class="c-sharp"&gt;public ActionResult MyPartialViewWithData()
        {
            return PartialView(&amp;quot;Data/Home/Home&amp;quot;, _entities.MyDataSet.ToList());
        }&lt;br /&gt;&lt;br /&gt;Is there a way to insert the PartialView with a reference to the model?  I found html.RenderPartial and some others but had trouble getting it to work.  &lt;br /&gt;&lt;br /&gt;Thanks in advance!&lt;/pre&gt;&lt;br /&gt; &lt;br /&gt;&lt;/p&gt;</description></item></channel></rss>