-
Declare Two or More Methods
How to declare two or more methods in C# program..How to implement that methods in the C# program
-
C# Error - Overload for method
I took a button in form.I have two classes emp and bonus.bonus class is inherited from emp class.If bonus is giving ie in dialog box if we select ‘Yes’ b ie bonus is added to sal and we get ts ie total sal along with eno.If bonus is not given ie in dialog box if we select ‘No’ we need to get only sal along with eno.The following pgm is working fine.class emp { private int...
-
JScript Use
What is the use of JScript? How to get value of input tag? How to change inner value of div tag from JavaScript.
-
Windows Service
What is Windows Service? Can we develop Windows Service using C#? If Yes, How? How to install or start Windows Service?
-
Where does the version dependencies recorded
A) Inside an assembly’s manifestB) Along with the project propertiesC) Both
-
Is there a way to force garbage collection?
Yes. Set all references to null and then call System.GC.Collect().If you need to have some objects destructed, and System.GC.Collect() doesn't seem to be doing it for you, you can force finalizers to be run by setting all the references to the object to null and then calling System.GC.RunFinalizers().
-
What is managed code?
Skill/Topic: IntermediateA) Code managed ouside the ILB) Code which can't be managed by the ILC) Code written in VB.NETD) Code to be compiled by IL
-
What is the difference between const and static read-only?
The difference is that static read-only can be modified by the containing class, but const can never be modified and must be initialized to a compile time constant. To expand on the static read-only case a bit, the containing class can only modify it:-- in the variable declaration (through a variable initializer).-- in the static constructor (instance constructors if it's not static).
-
YIELD Keyword
What is the purpose of YIELD Keyword in C#?
-
Variable Declaration and Assignment
What is difference between these two statement? if variable is declared and assign value in following two waysString sValue = (String)GridView1.DataKeys[GridView1.SelectedIndex].Value;String sValue = GridView1.DataKeys[GridView1.SelectedIndex].Value.ToString();
-
What does the keyword virtual mean in the method definition?
The method can be over-ridden.
-
C# Program to test efficient coding
You have several instances of the following class (User). Provide a class with three methods:"AddUser" accepts a User instance as a parameter and add it to a collection."GetUser" accepts a UserID as a parameter and returns the corresponding User instance. It is important that this executes quickly as it will be used often."GetOrderedUserArray" returns an array of User instances ordered by UserID....
-
-
-
Value Types are stored on the heap ..? Is it true/False ?
Skill/Topic: AdvancedA) TrueB) False
-
Singleton Class
Give an example of inbuilt Singleton Class in .NET.
-
-
-
Whitespace in XML Parser
When whitespace is encountered by an XML parser within the element content, how is it handled by the XML parser?
-
ByteArray Class
Write a class called ByteArray that implement allocating, reading and writing to an array of bytes. The runtime environment has a limitation. The maximum continuous memory size that it can allocated is 64k bytes. It can allocate many 64K ( or less) chunks. The ByteArray class should hide this limitation and support allocating arrays larger than 64K as in the following example :ByteArray ba = new ByteArray...
C# Interview Questions
Ans