| Next Tip?
Home » Archive

Articles in the Interview Questions Category

Asp.net, Interview Questions »

[27 Oct 2008 | One Comment | 305 views]

Generating RSS Feed : A simple way
Around a week back one of my colleagues need to geenrate an RSS Feed for Site. This is my try towards the same.
Here, I have used database of my site and try to generate a RSS Feed for my Site.
Anyone can use the same with a little change.
1. As this will generate a RSS Feed so there is no need to do more with design page only besides few following lines
<%@ Page Language=”C#” AutoEventWireup=”true” CodeFile=”RSSFeedGenerator.aspx.cs” Inherits=”RSSFeedGenerator” EnableViewState=”false”%>
<%@ OutputCache Duration=”300″ VaryByParam=”none” %>
<!DOCTYPE html PUBLIC …

CSharp, Interview Questions »

[27 Oct 2008 | No Comment | 313 views]

Nullables in C#
Defiition:
Nullable types are instances if System.Nullable. A nullable type can represent the normal range of values of its underlying value type plus an additional null value.
Purpose:
The purpose of this code-snippet to describe the use of nullable types with little different of a general type.
Following Console code-block tells the all above :
/* This Example is a part of different
* examples shown in Book:
* C#2005 Beginners: A Step Ahead
* Written by: Gaurav Arora
* Reach at : msdotnetheaven.com
* File Name: nullable.cs */
using System;
using System.Collections.Generic;
using System.Text;
namespace AStepAhead.Nullable
{
class nullableclass
{
static void Main(string[] args)
{
int? …

Interview Questions »

[5 Oct 2008 | No Comment | 691 views]

The answer is quite interesting with my stuff. Let me clear it in more writting:
1. When we compare two nulls then the result always ‘false’. The main reason is the null is not a value its neither an empty nor a empty space, so the actual result is null which places as null.
2. When we compare a null with another which has some value like some int value then the result is false. The actual result is false and not null.
Consider the following examples:
–null = null is null which is …

Get Adobe Flash playerPlugin by wpburn.com wordpress themes