Sunday 22 April 2012

Difference between Abstract class and interface. || what is abstract class || what is interface || Features of Abstract Classes and interfaces

Hi friends, in this article i will explain about the Difference between Abstract class and interface or what is abstract class or what is interface or Features of Abstract Classes and interfaces.
What is an Abstract class?
Abstract class is a class that cannot be instantiated, it exists extensively for inheritance and it must be inherited. There are scenarios in which it is useful to define classes that is not intended to instantiate; because such classes normally are used as base-classes in inheritance hierarchies, we call such classes abstract classes.

Friday 13 April 2012

PictureBox in VB.NET/C# || How to display image in windows forms || How to add image in windows form

Hi Friends, in this article I will explain about how to display image in windows forms.         
 First take one web form, 

 
File ----> Add New Project ----> Give the name Aspdotnet-kishore ----> OK
Drag and Drop PictureBox into the form from the ToolBox and double click on the form then Form1_Load event is create like below.
Private Sub Form1_Load (ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Then write the following code in the Form1_Load
 VB.NET Code:
 

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Dim img As Image = Image.FromFile("C:\new-star.gif")
        PictureBox1.Image = img
        PictureBox1.Width = 5000
        PictureBox1.Height = img.Width
       'PictureBox1.SizeMode = PictureBoxSizeMode.StretchImage

        'PictureBox1.Cursor = System.Windows.Forms.Cursors.Hand
    End Sub

C# Code:


private void Form1_Load(System.Object sender, System.EventArgs e)
{
     Image img = Image.FromFile("C:\\new-star.gif");
     PictureBox1.Image = img;
     PictureBox1.Width = 5000;
     PictureBox1.Height = img.Width;
}
  
And press Enter.Then the output is like below.
"If you like my blog or articles, you can appreciate by leaving your comments or Liking my Facebook pageAspdotnet-kishore, following on Google+ Aspdotnet-Kishore, Twitter  on AspdotnetKishore, Linked in Aspdotnet-Kishore, stumbling my posts on stumble upon and subscribing on  RSSfeed Aspdotnet-Kishore for free updates directly to your Email inbox . Watch my blog  for more articles." 
 
 
 
 
 
 
 

Thursday 12 April 2012

How to create Mater pages in ASP.NET || What is the use of Master Pages in ASP.NET || How to add Master page to .ASPX page

Master Page in ASP.NET:
Hi friends, in this article i will explain about how to create the master pages in ASP.NET.
What is the use of master pages?
1. It is mainly used to re usability like function. If we write the code in the master page then we can use this page in many pages.
© 2012-2018 Aspdotnet-Kishore.blogspot.com. All Rights Reserved.
The content is copyrighted to Kishore and may not be reproduced on other websites without permission from the owner.