Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>@lopkiju, I think that the MVC pattern would serve you much better than your current WebForms solution if you want that much control over the output HTML.<br> You can use Web Forms this way as you already do, but it is not designed to be used this way, so it will be a pain.</p> <p><strong>More detail</strong></p> <p>In my opinion, read some articles about the <a href="http://en.wikipedia.org/wiki/Separation_of_concerns" rel="nofollow noreferrer">Separation of Concerns</a> (also known as SoC) principle. If you apply it correctly, it can save you many-many headaches when you'll debug your app, and also for those people who you work with (eg. those who may have to read or modify your source code).</p> <p>My other tip for you is this:<br> You are right that you shouldn't do things like <code>&lt;% while (dataReader.Read()) %&gt;</code> in your View code. But perhaps there are better ways to make it more elegant than your current way.</p> <p>I think you should consider using some sort of ORM for these purposes. (LINQ to SQL, or even NHibernate.) If you get it, it will be much simpler. So much that you may not want to use <code>DataReader</code>s directly again. :-)</p> <p><strong>What I recommend for you</strong></p> <p>Simply, read the <a href="http://weblogs.asp.net/scottgu/archive/2009/03/10/free-asp-net-mvc-ebook-tutorial.aspx" rel="nofollow noreferrer">NerdDinner tutorial</a>, and build the samle app by yourself step-by-step.<br> After that, try to build a similar app that serves a different purpose by yourself while applying the same rules and design that you applied to the tutorial.</p> <p>I'm pretty sure you have the expertise to do it, and after actually doing something with it, you can pretty much get the feel of it.</p> <p>The tutorial <strong>also</strong> explains and includes the principles I mentioned above, which will be very much use to you.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload