Vishwamohan

Welcome to Vishwa's blog - Technology, Spirituality and More...

Certificate Error: Navigation Blocked

There are some situations especially in development or QA environment when you would to like ignore the SSL certificate. Generally this warning occurs when SSL certificate is either assigned to a different domain name, IP Address or self signed. You will most likely see the one of following error or warning messages when information is posted manually through Internet Explorer or FireFox browser. [More]

Using XMLWriter and XMLReader

This is a simple example for demonstrating how to use XMLReader or XMLWriter for reading or writing a XML file or XML String. I am using a Customer Entity which was created in previous examples. [More]

Data Transfer Objects (DTO) - Business Layer

I will be consuming the data which was returned by Data Access Layer in the form of XML, Dataset, DataTable, ArrayList and Custom (Data Transfer) Objects to populating my Business Object, which will be finally consumed by a User Interface and most likely a web page. In this example, I will use only one class, which will perform the CRUD operation on Customer Object by invoking method of Data Access Layer. Since I have added methods in data access layer to return Customer(s) data in form on XML, Dataset, DataTable, ArrayList and Custom (Data Transfer) Object. No matter in which form data is returned from data access layer, the business object will read that object and consume the data to make it ready for business object caller. [More]

Data Transfer Objects (DTO) - Data Access Layer

When you separate your business layer from data access layer in two different assembly, you come across a situation as which data transfer method will best fit you. In this example, I went through various Data Transfer Objects(DTO) which are currently available in .NET such as XML, DataSet, DataTable, ArrayList and Custom Data Transfer Object . One DTO generally maps to one Business Object. Each option has its pros and cons, so depending on project one should choose as what best fits the need. In the following code I have tried to use all the four possibilities. [More]

Freeze Column in GridView

The following example will demonstrate as how to freeze or fix one or more column in a GridView. I have used stylesheet to achieve this result. At present this solution only works in IE 7.0. The data source is a xml file containing product sales result. [More]

Speed Test: Generic List vs. ArrayList

It is very important to evaluate the most efficient way of passing data between layers. Many people recommend using ArrayList, some Generic List. But which one is the most efficient way to use? I thought to perform a speed test between Generic List and ArrayList in VS2005. Some people blindly accept that ArrayList is the fastest way. But is it true? Let’s have a real test by reading and writing hundred thousand records using each type and see the outcome. Knowing the fact that Collection, Data Table and XML is slower than these two but how much? Let’s put them to test too and compare the result. [More]

Code Review Template

It has been always a challenge in a development team to come up with a Standard Code Review Template for .NET. I struggled with the same issue and hence researched on the web to find out some code review guidelines which can help each developer and development team to evaluate those important criteria for a better development practice. This template also provides some important links to a developer to follow as a set of guidelines based on standard practices. [More]

Server Error: HTTP Error 500.19 - Internal Server Error

You might have come across this error while working on a WCF project on Vista, IIS 7.0 with Visual Studio 2005. Actually Microsoft has tightened the security on VISTA and most of the time it is annoying when it asks your permission. Following is the detail error message I received while trying to run a WCF project, however I found a simple solution to fix it. [More]

AJAX Error: 'Sys' is undefined

If you are using AJAX enabled web site or project, you may come across this error message. I got this error message too and spent few hours to fix this problem. I tried finding all possible solutions on Google and finally concluded with following three steps. [More]

ADO.NET – Best Practices for Data Access

This article will first talk about top 5 best practices you should use while accessing database and then demonstrate how to properly use SqlConnection, SqlCommand and SqlDataAdapter objects while working with data using stored procedure or inline SQL for optimal performance.
[More]