Hello friends ,
i am new in C#.net.I read about Abstraction,Inheritance etc. in Console application.but how can use these concepts in Windows or web apps.I searched it on google but did not find appropriate solution.
Thankx in advance.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
maulik patelRank #4,413 · 345 reputationPosted Jun 7, 2015, 10:44 PM EDT
look into below code where you find real way to use abstraction.
{
abstract class DB
{
public abstract void Connect();
public string DBIpAddress()
{
return “10.10.0.1”;
}
}
Class Sqlserver: DB
{
public override void Connect ()
{
Console.write(“This method will connect SQL server”);
}
}
Class Oracle : DB
{
public override void Connect()
{
Console.write(“This method will connect Oracle Server”);
}
}
}