Thứ Ba, 30 tháng 12, 2008

Dot Net Interview Questions part 1

1.What method do you use to explicitly kill a users session?

Ans : Syntax: Session.Abandon()

Note : The Abandon method destroys all the objects stored in a Session object and releases their resources.If you do not call the Abandon method explicitly, the server destroys these objects when the session times out.

2.What methods are fired during the page load?

Ans : Init() ,Load(),PreRender(),Unload().

3.What data type does the RangeValidator control support?

Ans : Integer,String and Date.

4.Which method do you invoke on the DataAdapter control to load your generated dataset with data?

Ans : Fill() method.

5.Which control would you use if you needed to make sure the values in two different controls matched?

Ans : CompareValidator Control

6.What base class do all Web Forms inherit from?

Ans : The Page class.

7.Explain the differences between Server-side and Client-side code?

Ans : Server-side code executes on the server. Client-side code executes in the context of the clients’ browser. you store the information about the user’s locale?

Ans : System.Web.UI.Page.Culture

9.Can you edit data in the Repeater control?

Ans : No, it just reads the information from its data source.

10.Which template must you provide, in order to display data in a Repeater control?

Ans : ItemTemplate.

11.How can you provide an alternating color scheme in a Repeater control?

Ans : AlternatingItemTemplate.

12.Name two properties common in every validation control?

Ans : ControlToValidate property and Text property.

13.Is String is Value Type or Reference Type in C#?

Ans : String is an object (Reference Type).

14.What is the difference between Server.Transfer and Response.Redirect? Why would I choose one over the other?

Ans : Server.Transfer transfers page processing from one page directly to the next page without making a round-trip back to the client’s browser. This provides a faster response with a little less overhead on the server. Server.Transfer does not update the clients url history list or current url. Response.Redirect is used to redirect the user’s browser to another page or site. This performas a trip back to the client where the client’s browser is redirected to the new page. The user’s browser history list is updated to reflect the new address.

15.What is the Global.asax used for?

Ans : The Global.asax (including the Global.asax.cs file) is used to implement application and session level events.

16.How many classes can a single .NET DLL contain?

Ans : It can contain many classes.

17.What is portable executable (PE)?

Ans : The file format defining the structure that all executable files (EXE) and Dynamic Link Libraries (DLL) must use to allow them to be loaded and executed by Windows. PE is derived from the Microsoft Common Object File Format (COFF). The EXE and DLL files created using the .NET Framework obey the PE/COFF formats and also add additional header and data sections to the files that are only used by the CLR.

18.What is strong name?

Ans : A name that consists of an assembly’s identity—its simple text name, version number, and culture information (if provided)—strengthened by a public key and a digital signature generated over the assembly.

19.What is Code Access Security (CAS)?

Ans : CAS is the part of the .NET security model that determines whether or not a piece of code is allowed to run, and what resources it can use when it is running. For example, it is CAS that will prevent a .NET web applet from formatting your hard disk.

20.What are the different types of assemblies?

Ans : Private, Public/Shared, Satellite

21.Which namespace is the base class for .net Class library?

Ans : system.object

22.How do you create threading in .NET? What is the namespace for that?

Ans : System.Threading.Thread .

23.What is the difference between ref & out parameters?

Ans : An argument passed to a ref parameter must first be initialized. Compare this to an out parameter, whose argument does not have to be explicitly initialized before being passed to an out parameter.

24.What are indexers?

Ans : Indexers are similar to properties, except that the get and set accessors of indexers take parameters, while property accessors do not.

25.What are the access-specifiers available in c#?

Ans : Private, Protected, Public, Internal, Protected Internal.

Chôm từ :

21 nhận xét:

  1. Monique, a Leaf fan, set up this absolutely persistent to believe. Now, let me regarding out that this was in no way an try to official one cooperate is raise than the other. It was objective a regarding to glory two things.

    Trả lờiXóa
  2. I love your work, i've added a link on my website to yours.

    Trả lờiXóa
  3. Wonderful post worthy of any thumbs way up. Have any other wonderful inexpensive suggestions?

    Trả lờiXóa
  4. A clue just what i'm speaking about.

    Trả lờiXóa
  5. I feel the key reason why I ran across a great deal of my preferred weblogs is due to your blogroll! Numerous thanks

    Trả lờiXóa
  6. I had been seeking the info for numerous days and right after that My spouse and i slide somewhat hit-or-miss right here , thanks a great deal sell silver

    Trả lờiXóa
  7. The moment you find out of any please talk about. Several thanks!

    Trả lờiXóa
  8. Merely declaring cheers won't often be all you'll need, as a result of this remarkable clearness in your writing.

    Trả lờiXóa
  9. This informative article has been ideal for the directions I was seeking. graffiti

    Trả lờiXóa
  10. I'll probably be returning for the blog website for added rapidly.

    Trả lờiXóa
  11. Which doesn't make sense at all. You do have a excellent thought involving what's happening

    Trả lờiXóa
  12. I do believe it is definitely extraordinary just how valuable it absolutely was when I read it

    Trả lờiXóa
  13. Water Heater The idea and then we all can discover that!

    Trả lờiXóa
  14. I have located a superb deal exciting things the following. Maintain on. seo in birmingham

    Trả lờiXóa
  15. I own a remarkable believed for this

    Trả lờiXóa
  16. Outstanding Evaluation! I fundamentally trust pretty much all you could talked about inside your post,

    Trả lờiXóa
  17. I came across this certain post by a analysis on-line

    Trả lờiXóa
  18. In my opinion it really is a excellent one specific pittsburgh bachelor party

    Trả lờiXóa
  19. Thanks just for that may wonderful post! I'll bookmark your blog post and appearance but again the following regularly

    Trả lờiXóa
  20. That doesn't develop any sense. There's a wise choice involving what's going on

    Trả lờiXóa
  21. Hello internet site owner! These days making use of Search engines so when a Search engine optimizer

    Trả lờiXóa