How would you implement inheritance using VB.NET/C#?

Answers were Sorted based on User's Feedback



How would you implement inheritance using VB.NET/C#? ..

Answer / raghumadhav tirunagari


Derived Class : Basecalss
VB.NEt : Derived Class Inherits Baseclass

Is This Answer Correct ?    1 Yes 0 No

How would you implement inheritance using VB.NET/C#? ..

Answer / rajender chauhan

C# : Class A:B
VB.Net Class A Inherits B

Is This Answer Correct ?    0 Yes 0 No

How would you implement inheritance using VB.NET/C#? ..

Answer / mr vinod kumar

When we set out to implement a class using inheritance, we must first start with an existing class from which we will derive our new subclass. This existing class, or base class, may be part of the .NET system class library framework, it may be part of some other application or .NET assembly, or we may create it as part of our existing application. Once we have a base class, we can then implement one or more subclasses based on that base class. Each of our subclasses will automatically have all of the methods, properties, and events of that base class ? including the implementation behind each method, property, and event. Our subclass can add new methods, properties, and events of its own - extending the original interface with new functionality. Additionally, a subclass can replace the methods and properties of the base class with its own new implementation - effectively overriding the original behavior and replacing it with new behaviors. Essentially inheritance is a way of merging functionality from an existing class into our new subclass. Inheritance also defines rules for how these methods, properties, and events can be merged. In VB.NET we can use implements keyword for inheritance, while in C# we can use the sign ( :: ) between subclass and baseclass.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More ASP.NET Interview Questions

You are creating a Web site for Your company. You receive product lists in the form of XML documents. You are creating a procedure to extract information from these XML documents according to criteria that your users will select. When a user makes a request, you want the results of these requests to be returned as quickly as possible. What should you do? A . Create an XmlDataDocument object and load it with the XML dat Use the DataSet property of the object to create a DataSet object. Use a SQL SELECT statement to extract the requested dat B . Create an XmlDataDocument object and load it with the XML data. Use the SelectNodes method of the object to extract the requested data. C . Create an XPathDocument object and load it with the XML data. Call the CreateNavigator method to create an XPathNavigator object. Call the Select method of the XPathNavigator object to run an XPath query that extracts the requested data. D . Create an XmlReader object. Use the Read method of the object to stream through the XML data and to apply an XPath expression to extract the requested data.

1 Answers   Syntax Softtech,


What are the Types of session management in ASP.NET

0 Answers   Microsoft,


how to use web services with code?(with example code)

1 Answers   Accenture,


What is server infrastructure & server components?

0 Answers  


Define web.config in .net?

0 Answers  






Explain in what order a destructors is called.

0 Answers  


What is the difference between session and application?

0 Answers  


I’m having some trouble with cas. How can I diagnose my problem?

0 Answers  


With out Web.config can we executes the application?

10 Answers   Valtech,


What is WCF? Pls Explain clearly with exmple.

3 Answers   HCL, iGate,


How can you apply a theme to your asp.net application?

0 Answers  


under which namespaces connection strings can be defined?

4 Answers  


Categories