Archives for November 2012

Top 10 ASP.NET MVC Best Practices

Are you using the best ASP.NET  practices or are you  not using any methods properly? This article will elaborate the 10 best ASP.NET practices which can help in efficiently using ASP.NET MVC Framework 4. Before you can benefit from these practices, you must have ASP.NET MVC 4 or later and Microsoft Visual Studio. One of the best features of MVC is that it separates the model, view, and controllers in an application; thus maintaining a clean separation which makes testing a lot faster and easier than before. Programmers also benefit from the contract being more clearly defined and articulated.


Read the rest of the article here:

How to Configure Secure Sockets Layer Connection

If you are one of those people who want to have the connection in the browser and the server encrypted but don’t know how to set it up, this article will explain how it can be done. SSL is a protocol to help transmit sensitive data safely on the internet. Before you can get a certificate, you need to submit a certificate signing request which contains your details to the certification authority. You will also need to get and use a digital certificate which will be best explain in the link below. Once done, test your connection to confirm if SSL is now available in your website.


Read the rest of the tutorial here:


How to Handle Exeption in ASP.NET Web API

When there are unhandled exceptions in the Web API controller class, most of the actual exceptions are indicated by the HTTP 500 status code or also known as the Internal Server Error. This error does not provide useful information to the client so lets tweak it up a bit to display. You can fine tune and customize your HTTP errors to be sent to the client’s browser in a more user-friendly way.


With this tweak, clients won’t be seeing that ugly generic “Internal Server Error” message. Using only the HttpResponseException class, you can return meaningful error to your clients.


Read the rest of the story here:

How to Use ASP.NET Repeater Control

If you don’t know how you can loop out datasets and build tables and you do not know how you can display raw data with just one column, ASP.NET repeater control can provide you with what you’ve been missing. First create page then insert the repeater control. Then get the data you need to have a repeater control. Here is a sample of the code and what you can do with repeater control:

  1. ….
  2. <asp:Repeater ID=”catlist” runat=”server”>
  3. <HeaderTemplate>
  4. <tr>
  5. <td class=”imgspace”>
  6. <img src=”Images/areas.jpg” width=”91″ height=”28″ class=”bigtext”>
  7. </td>
  8. </tr>
  9. </HeaderTemplate>
  10. <ItemTemplate>
  11. <tr>
  12. <td>
  13. <div align=center>
  14. <asp:HyperLink class=”text”
  15. NavigateUrl=”<%# “mainframeset.aspx?CatType=” +
  16. DataBinder.Eval(Container.DataItem,”Sub_Category_ID”)%>”
  17. Text=”<%#DataBinder.Eval(Container.DataItem, “Sub_Category_Text”)%>”
  18. runat=”server” target=”mainFrame” ID=”Hyperlink1″ NAME=”Hyperlink1″/>
  19. <br></div>
  20. </td>
  21. </tr>
  22. </ItemTemplate>
  23. <FooterTemplate>
  24. <tr>
  25. <td>

Read the rest of the article here:

How to Use Page Inspector to Examine Web Forms

As a web developer, you need to constantly check the runtime source that is being generated in HTML web forms and views. Microsoft Visual Studio Page Inspector is a diagnostic tool in which it helps you dissect and observe HTML source and styling of your web pages.  It not only gives integrated HTML source styling, but also provides you with a detailed information in an easy-to-read form. This article will explain how you can use Microsoft Visual Studio page inspector to use with ASP.NET web forms.


Using page inspector helps you analyze, optimize, and inspect resultant HTML markup of the page.


Read the rest of the article here:

How to Rotate ASP.NET Image Control using HTML5 Canvas

The canvas element is a tag in which you can embed inside HTML so you can draw graphics using JavaScript API. This article will explain how you can use HTML 5 Canvas to rotate an image that is served by ASP.NET Image Control.

To give you an idea, first, open Microsft Visual Studio 2010 or any version you have. The declare a markup which has an HTML5 canvas dimension of 400×400 and your ASP.NET Image control display be set to none. Then, you’ll have to declare a JavaScript Code inside the <head> element.


Let us take a closer look at what you can do and what it can do to your website here:

Improved Performance of Websites Using Asychronous Partial Views

You may encounter your website having a performance issue when you build it with ASP.NET MVC. This problem, although rare can be solved using Asynchronous Partial views. This article will cover how you can improve ASP.NET MVC website performance using MVC partial views along with HTML5, JQuery, and JavaScript to make your site feel responsive and fast. Your site will just feel faster, not speed up the entire speed of your website. You are assumed to have tried out different things like increasing your database performance like adding proper indexes, optimizing queries, and caching data.


Read the rest of the tutorial here:

How to Call and Send Reports Programmatically

Do you know that you can call the execution engine on your server through ReportExecution2005.amx? All you need to do is generate a project class in this service and you’ll be get the results you need in no time. Other than that, you’ll have to change the web config, then give it the correct credentials and path to your server. You’ll also need a few lines of code that are available in the link below. After that, call and report then have the parameters reported automatically during the call.


There are several things to consider while doing this but sometimes it is easier to use Reporting Service Web Services SSRS to generate reports because the look better than having it programmatically done.



Get the tutorial here: 

Infographic: The Cost Of Bugs

Bugs and defects in a software causes a huge loss to an organization. A single bug or defect can be a loss that amounts to 55 billion dollar a year, or costing about 133,000 per minute. Fixing bugs are cheaper than creating a new program. This infographic displays that the more severe the software bugs are, the more loss the organization will encounter. On the side note, the cost of correcting bugs can amount to more than $7,000 during the testing phase and about $14,102 when the bug is corrected after the release of the software.  This just shows how important that bugs should be tracked and why organizations take bug zapping seriously to their software.

Read full article here:

How to Create Simple Scheduler in ASP.NET

In this article, I will show how to keep our Scheduler in control, up-to-date, and easy to use. It will explain how Scheduler set up can be done in as easy as 5 steps and be covered in less than five minutes. This article will explain a new step-by-step guide to create a simple, yet elegant calendar/scheduler in ASP.NET MVC3/MVC4. The scheduler features daily, monthly, and weekly views, highlighting of the current day, data load and save, AJAX loading, and a drag and drop feature. You’ll just need to create a new project using Visual Studio, set up a database, and create a simple scheduler using c#.


Read full tutorial here: