This is default featured slide 4 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 1 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 2 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 4 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

Me And My Respected Teacher Mr Kamal Sheel Mishra

Mr. K.S. Mishra is HOD of Computer Science from SMS Varanasi where I have completed my MCA

Me And My Respected Teacher Mr Udayan Maiti

Mr. Udayan Maiti is a senior .Net Expert and has guided many professionals of multi national Companies(MNC)

Me And My Best Friend Mr Ravinder Goel

Mr. Ravinder Goel is a senior Software Engineer and now he is working Wipro Technology

Wednesday 30 May 2012

Out and Ref Keyword in C#.Net

Different Of out and ref Keyword in .net........................
  1.  both use for multiple return in single method means by using this we can  return multiple value or multiple output
  2. the  main  difference  between out and ref  are  that for ref we have  to intilize and out no need for intilize

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace out_ref
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}

public void sum(int i, int j, out int ad, out int su, out int mu, out int di)
{
ad = i + j;
su = i - j;
mu = i * j;
di = i / j;
}

public void sumbyref(int i, int j, ref int ad, ref int su, ref int mu, ref int di)
{
ad = i + j;
su = i - j;
mu = i * j;
di = i / j;

}

private void button1_Click(object sender, EventArgs e)
{
int i = Convert.ToInt32(textBox1.Text);
int j = Convert.ToInt32(textBox2.Text);
int a, b, c, d;
sum(i, j, out a, out b, out c, out d);
MessageBox.Show("sum=" + a.ToString() + "subtraction =" + b.ToString() + "  " +"multiplication=" + c.ToString() + " " + "division =" + d.ToString());
}

private
 void button2_Click(object sender, EventArgs e)
{
int i = Convert.ToInt32(textBox1.Text);
int j = Convert.ToInt32(textBox2.Text);
int a=0, b=0, c=0, d=0;
sumbyref(i, j, ref a, ref b, ref c, ref d);
MessageBox.Show("sum=" + a.ToString() + "subtraction =" + b.ToString() + "  " +"multiplication=" + c.ToString() + " " + "division =" + d.ToString());
}


 private void button3_Click(object sender, EventArgs e)
{

char[] ch = textBox1.Text.ToCharArray();
{
int i = ch.Length;
MessageBox.Show(ch[0].ToString() + ch[i - 1].ToString());
}
}
}
}





Tuesday 15 May 2012

How to indexing GridView record in runtime....



// how  to  indexing  gridviw record



protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)

    
{

   if (e.Row.RowType == DataControlRowType.DataRow)

        
{

    
((Label)e.Row.Cells[0].Controls[1]).Text =

(Convert.ToInt32(e.Row.RowIndex)+1).ToString();


}


    }