<?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>Migrating from ASP to ASP.NET</title><link>http://forums.asp.net/29.aspx</link><description>Discuss moving from classic ASP to ASP.NET. </description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Re: asp subs to asp.net</title><link>http://forums.asp.net/thread/3171628.aspx</link><pubDate>Tue, 19 May 2009 05:15:31 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:3171628</guid><dc:creator>Vishal</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/3171628.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=29&amp;PostID=3171628</wfw:commentRss><description>&lt;p&gt;Have you tried using a Literal control? You can put any HTML into it and thus you will not have to use the asp:img control?&lt;/p&gt;
&lt;p&gt;Let me know if I&amp;#39;ve understood your problem correctly.&lt;/p&gt;</description></item><item><title>asp subs to asp.net</title><link>http://forums.asp.net/thread/3171333.aspx</link><pubDate>Tue, 19 May 2009 02:36:06 GMT</pubDate><guid isPermaLink="false">4c671506-2930-414c-a40b-8bf57ded5924:3171333</guid><dc:creator>thinking2</dc:creator><slash:comments>0</slash:comments><comments>http://forums.asp.net/thread/3171333.aspx</comments><wfw:commentRss>http://forums.asp.net/commentrss.aspx?SectionID=29&amp;PostID=3171333</wfw:commentRss><description>&lt;p&gt;I am new to .net but am familiar with classic asp. I do not understand how to use the asp:image component within a sub like I would have done in classic asp.&lt;/p&gt;
&lt;p&gt;In Classic asp I would use a sub for demonstration purposes&lt;br /&gt;&amp;lt;%&lt;br /&gt;Sub&amp;nbsp;openShadow()&lt;br /&gt;%&amp;gt;&lt;br /&gt;&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;0&amp;quot; border=&amp;quot;0&amp;quot;&amp;gt;&lt;br /&gt;&amp;lt;tr&amp;gt;&lt;br /&gt;&amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;&amp;lt;%=getImgRoot() %&amp;gt;shadow_top_left.jpg&amp;quot; border=&amp;quot;0&amp;quot; /&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;&amp;lt;td &amp;gt;&amp;lt;img src=&amp;quot;&amp;lt;%=getImgRoot() %&amp;gt;shadow_top_mid.jpg&amp;quot; border=&amp;quot;0&amp;quot; /&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;&amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;&amp;lt;%=getImgRoot() %&amp;gt;shadow_top_left.jpg&amp;quot; border=&amp;quot;0&amp;quot; /&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;&amp;lt;/table&amp;gt;&lt;br /&gt;&amp;lt;%&lt;br /&gt;End Sub&lt;/p&gt;
&lt;p&gt;call openShadow()&lt;br /&gt;%&amp;gt;&lt;/p&gt;
&lt;p&gt;I do not know how to do the above in .Net as a Sub so I made a Function but can not use the asp:img because it sees it as a string of text. Also I really want to double up on all my quotes. &lt;/p&gt;
&lt;p&gt;########&amp;nbsp; BEGIN .NET SAMPLE&lt;/p&gt;
&lt;p&gt;Public Shared Function openShadow(ByVal xWidth As Integer) As String&lt;br /&gt;Dim str As String&lt;br /&gt;str = &amp;quot;&amp;lt;table width=&amp;quot;&amp;quot;&amp;quot; &amp;amp; xWidth &amp;amp; &amp;quot;&amp;quot;&amp;quot; cellpadding=&amp;quot;&amp;quot;0&amp;quot;&amp;quot; cellspacing=&amp;quot;&amp;quot;0&amp;quot;&amp;quot; border=&amp;quot;&amp;quot;0&amp;quot;&amp;quot;&amp;gt;&amp;quot; &amp;amp; _&lt;br /&gt;&amp;quot;&amp;lt;tr&amp;gt;&amp;quot; &amp;amp; _&lt;br /&gt;&amp;quot;&amp;lt;td&amp;gt;&amp;lt;asp:Image ImageUrl=&amp;quot;~/images/shadow_top_left.jpg&amp;quot; width=&amp;quot;9&amp;quot; Height=&amp;quot;9&amp;quot; GenerateEmptyAlternateText=&amp;quot;true&amp;quot;&amp;nbsp; runat=&amp;quot;server&amp;quot; /&amp;gt;&amp;lt;/td&amp;gt;&amp;quot; &amp;amp; _&lt;br /&gt;&amp;quot;&amp;lt;td&amp;gt;&amp;lt;asp:Image ImageUrl=&amp;quot;~/images/shadow_top_middle.jpg&amp;quot; width=&amp;quot;9&amp;quot; Height=&amp;quot;9&amp;quot; GenerateEmptyAlternateText=&amp;quot;true&amp;quot;&amp;nbsp; runat=&amp;quot;server&amp;quot; /&amp;gt;&amp;lt;/td&amp;gt;&amp;quot;&amp;nbsp;&amp;amp; _&lt;br /&gt;&amp;quot;&amp;lt;td&amp;lt;asp:Image ImageUrl=&amp;quot;~/images/shadow_top_right.jpg&amp;quot; width=&amp;quot;9&amp;quot; Height=&amp;quot;9&amp;quot; GenerateEmptyAlternateText=&amp;quot;true&amp;quot;&amp;nbsp; runat=&amp;quot;server&amp;quot; /&amp;gt;&amp;lt;/td&amp;gt;&amp;quot; &amp;amp; _&lt;br /&gt;&amp;quot;&amp;lt;/tr&amp;gt;&amp;quot; &amp;amp; _&lt;br /&gt;&amp;quot;&amp;lt;/table&amp;gt;&amp;quot;&lt;br /&gt;Return str&lt;br /&gt;str = Nothing&lt;br /&gt;End Function&lt;/p&gt;
&lt;p&gt;&amp;lt;%=openShadow(&amp;quot;1002&amp;quot;) %&amp;gt;&lt;/p&gt;
&lt;p&gt;########&amp;nbsp; END .NET SAMPLE&lt;/p&gt;
&lt;p&gt;What am I missing? In classic asp I prefer Sub Procedures over a ton of include files. Can I do the same as I did in Calssic ASP but within .Net? Should I do it this way or is there a better way?&lt;/p&gt;</description></item></channel></rss>