by ExpertsBlog
25. February 2012 20:28
Polymorphism means same method/function can perform completely different task or can show completely different behavior in different classes or same class, in case if methods are in different classes then they are related with each other by base and drive class relationships.
There are two types of polymorphism:
Compile time polymorphism (Method overloading)
Run time polymor...
[More]
by ExpertsBlog
25. February 2012 19:26
Run time polymorphism allows us to invoke derived class methods through a base class reference during run-time. This is also called runtime
binding.
An example is shown below.
namespace TestApp
{
public class DrawingBaseClass
{
public virtual void Draw()
{
Console.WriteLine("I am a Base Class drawing object.");
}
}
public cla...
[More]
by ExpertsBlog
26. November 2011 13:20
Sometime we get requirement to trigger an event like button click event from JavaScript code. This we can achieve through
"__doPostBack(eventTarget, eventArgument)" function. __doPostBack is not new to ASP.Net, if we see view source of the asp.net page then we can see this __doPostBack function in our asp.net generated HTML code.
Whenever asp.net page posted back to the server, as...
[More]
ae35f1d6-b88e-43de-945f-c226cd78d29d|2|1.5
Tags:
ASP.NET
by ExpertsBlog
19. November 2011 09:40
Here are important SQL Server questions part -2 interviews:
Part -1: http://www.expertsblog.in/post/Important-SQL-Interview-Questions.aspx
Q. Select all employees who does not have phone?
SELECT emp_name FROM Employee WHERE (emp_id NOT IN (SELECT DISTINCT emp_id FROM Phone))
Q. Select the employee name who is having more than one phone number.
SELECT emp_name FROM Employee WHER...
[More]
5e9f3ce4-f769-429b-b0b8-9bd1622361fc|1|4.0
Tags:
by ExpertsBlog
10. November 2011 19:44
Here are some important SQL Server questions which often ask in interviews:
Q. What are the benefits of views and stored procedures instead of large and heavy duty queries?
These can reduce network traffic, because client will send to server only store procedure or view name perhaps with some parameters instead of large queries. Views can be used to facilitate permission management also, cause...
[More]
by ExpertsBlog
10. November 2011 17:50
Often .Net developers in the initial years of their programming careers faces some questions regarding coding practices and way of programming that minimize the chances of Bugs/Errors.
Following are some guideline which might be helpful to achieve some good programming practices:
Clarity and Consistency
Always ensure that you are applying all coding standards consistently in your project. And d...
[More]
587450d1-cb52-414a-9295-168670ca1a02|0|.0
Tags:
ASP.NET | C#
by ExpertsBlog
19. October 2011 20:20
.NET Framework provides a class specifically to create XML documents, the System.Xml.XmlTextWriter class. By using this class we can create XML documents with easy. In this article we'll look at using the XmlTextWriter class to create XML documents.
The XmlTextWriter class contains following important methods:
WriteStartDocument() - we should use this m...
[More]
3365bb95-9ca1-4778-a09b-b85efa423212|1|5.0
Tags:
ASP.NET | XML
by Administrator
13. October 2011 16:18
We often need client side JavaScript validation for validate email address. Below is example for validating email address.
function validateEmail()
{
var email = document.getElementById("txtemail").value;
var Isvalid=1;
var emailRegex = new RegExp(/^[a-zA-Z0-9._-]+@gmail\.com$/); // This is for specific d...
[More]
by Administrator
12. October 2011 21:33
In web development we often need client side JavaScript validation for checking only characters. Below is example for checking any non-alphabets characters, and no spaces or special characters.
function validateName()
{
var valid=1, checkchar;
var name = document.getElementById('txtName').value;
name = name.toLower...
[More]
by Administrator
12. October 2011 20:54
In web development we often need client side JavaScript validation for checking non-numeric characters. Below is example for checking any non-numeric characters, and the length is not null.
function validateEmpId()
{
var empid = document.getElementById("txtempid").value;
var IsempValid=1;
if(isNaN(empid) || empid.length==0)
...
[More]