C sharp Interview Question and answer

1) What is OOPS?

OOPS is abbreviated as Object Oriented Programming system in which programs are considered as a collection of objects. Each object is nothing but an instance of a class.

2) Write basic concepts of OOPS?

Following are the concepts of OOPS:

Abstraction
Encapsulation
Inheritance
Polymorphism
3) What is a class?

A class is simply a representation of a type of object. It is the blueprint/plan/template that describes the details of an object.

4) What is an Object?

Call JavaScript Function From Code Behind C#

you can add in codebehind 

Page.ClientScript.RegisterStartupScript(this.GetType(),"CallYourFunction","YourFunction()",true);

 

and also define javascript code 

same as bellow:

string str="<script>alert(\"ok\");</script>";

Page.ClientScript.RegisterStartupScript(this.GetType(), "Script", str, false);

Subscribe to c#