You must Sign In to post a response.
  • Category: .NET

    .net language tools releted question

    what is difference between method, property and event?
    what is difference between rich-textbox and textbox?
    what is difference between list-view and list-box?
  • #768850
    Hi,

    Without knowing anything related to .net and what are those concepts, you didn't understand the differences between those. If you are a fresher my suggestion is join in any institute and trained all those concepts, if you are not interested to get train from institute then learn the concepts at-least from online forum by searching the concept in Google then only you can understand the differences.

    Hope this will help you...

    --------------------------------------------------------------------------------
    Give respect to your work, Instead of trying to impress your boss.

    N@veen
    Blog : http://naveens-dotnet.blogspot.in/

  • #768852
    I accept Naveen's point.
    What you are asking is very basic level question which a beginner will go through.
    So please start your beginning level course by self-based or any training institutional level.

    Thanks,
    Mani

  • #768873

    Hai Swati,
    Please find the answers for your questions:
    Q. what is difference between method, property and event?
    A. Methods are the functions which may or may not returns the value. It depend on the return type, if it is void, then it will not returns the value else it will return the value.

    public void Show()
    {
    Console.WriteLine("Show Method");
    }

    Properties are the type which has the setter and getter attributes attached to it.
    e.g.

    public int Id { get; set;}

    Events are the types which get trigger when an action is taken like on clicking the button, Button_Click event gets fired:

    protected void Button1_Click(Object sender, EventArgs e)
    {
    // do something
    }

    Q. what is difference between rich-text-box and text-box?
    A. Rich text box is special type of text-box which has the formatting capabilities. We can format our text like color, style etc. While the text-box will not these additional features. Both are used for the data input.
    Q. what is difference between list-view and list-box?
    A. List-view is to display the records in the various list formats while the List-box will have only the list format. Both are used to display the data. We can display the data in different views in List-view while we can only display the straight data using the List-box.
    Hope it will be helpful to you.


    Regards,
    Pawan Awasthi(DNS MVM)
    +91 8123489140 (whatsApp), +60 14365 1476(Malaysia)
    pawansoftit@gmail.com

  • #768888
    Properties are a useful way of expressing a feature of an object, allowing get/set in a common way that can be used by APIs like data-binding, reflection and serialization
    Methods (C# doesn't have functions) are better for expressing things that either change the state, or which have an expectation of taking some time and not necessarily being reproducible. They don't tend to work in binding / serialization etc

    Thanks
    Koolprasd2003
    Editor, DotNetSpider MVM
    Microsoft MVP 2014 [ASP.NET/IIS]

  • #768893
    Property is a type of method that shows state of an Object. We can thing property as adjectives that describe object like Caption, backcolour etc.
    Methods/Functions are for changing or doing something on the Object. It represents the behavior performed by an object. Like Move, Remove, Add etc.

    Event are Objects which means that something. Event is message sent by an object to signal an activity

  • #768899
    [2] what is difference between rich-textbox and textbox?
    A RichTextBox is a better choice when it is necessary for the user to edit formatted text, images, tables, or other rich content while TextBox requires less system resources then a RichTextBox . Difference with Code snippet

    this.RichtextBox = Word (Open,Save {RTF,TXT,Images,Fonts etc})
    TextBox = INPUT (Just Text Or Number)


Sign In to post your comments