Note that there are some explanatory texts on larger screens.

plurals
  1. POSimple ASP.NET MVC example
    primarykey
    data
    text
    <p>i need some advice on building a real environment MVC project.</p> <p>I already went thru all the tutorials in asp.net. But i found that most of the tutorials are using ninject, Entity Framework(EF) or linq to sql(L2S)... But i do not want to use 3rd party solution or some others "new" language.</p> <p>My requirements:</p> <ol> <li><p>i want to connect DB using connectionstrings :</p> <p><code>&lt;connectionStrings&gt; &lt;add name="SQLConn" connectionString="Data Source=MyPC\SQLEXPRESS;Initial Catalog=MyDB;Integrated Security=True" providerName="System.Data.SqlClient" /&gt; &lt;/connectionStrings&gt; </code></p></li> <li><p>A CRUD page which grab from Database using the above connectionstring(SQLConn), with a listing page, update, delete and create new record page + validation at Model.</p></li> <li><p>I prefer to have a raw repository pattern, instead of using EF, L2S or some others "extra" tools. i want to use "SELECT * FROM tblTest...". </p></li> <li><p>i do not want to include SQL query everywhere on my page, i prefer include all of them in Model.</p></li> </ol> <p>My problems:</p> <ol> <li><code>public SqlConnection conn = new SqlConnection("SQLConn");</code> This method seems only working in webform pattern, may be i make a mistake.</li> <li>How to develop in Repository pattern with Model validation?</li> </ol> <p>I just need some ideas how to make all these link up together. With the List page as example is good enough. or any sites/blogs for me to refer? Example with MVC 3 is fine too.</p> <p>Thanks.</p> <p>Jason</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    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.
 

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