Thursday 4 October 2012

Some Questions On .Net #4


Q1. In which database is the information, such as membership, role management, profile & web parts personalization, stored?
Ans. The aspnetdb database stores all information.

Q2.What is state management?
Ans. State management is used to store information requests. The state management is used to trace the information or data that affect the state of the application.

Q3. What do you understand by aggregate dependency?
Ans. Aggregate dependency allows the multiple dependencies to be aggregated for content that depends on more than one resource. In such type of dependency, you need to depend on the sum of all defined dependency to remove a data item from the cache.

Q4. How can you ensure that no one has tempered with viewstate in a web page?
Ans. To ensure that no one has tempered with viewstate in a web page, set the enableviewstatemac property to true.

Q5. What is the cookie less session?
Ans. ASP.NET manages the session state in the same processses the request and does not create a cookie. It is known as cookie less session.

Q6. What is a round trip?
Ans. The trip of a web page from the client to the server & then back to the client is known as a round trip.

Q7  What are the major built-in objects in ASP.NET?
Ans. The major built-in objects in ASP.NET are as follows:
application
request
response
server
session
context
trace

Q8. Why do we need nested master pages in a web site?
Ans. When we have several hierarchical levels in a web site, then we use nested pages in the web site.

Q9.How can you dynamically add user controls to a page?
Ans. User controls can be dynamically loaded by adding a web user control page in the application & adding the control on this page.

Q10. What type of code, client-side or server-side, is found in a code-behind file of a web page?
Ans. A code-behind file contains the server-side code, which means that the code contained in a code-behind file is executed at the server.    


Download this article as PDF 

 

Wednesday 3 October 2012

Some Questions On .Net #3


Q1. What setting must be added in the configuration file to deny a particular user from accessing the secured resources?
Ans. To deny a particular user from accessing the secured resources, the web.config file must contain the following code:
       <authorization>
                 <deny user="username"/>
       </authorization>

Q2. What are the event handlers that can be included in the global & file?
Ans. The global.asax file contains some of the following important event handlers:
                                application_error
        application_start
                                application_end
        session_start
                                session_end

Q3. What is the difference between page-level caching & fragment caching?
Ans. In page-level caching, an entire web page is cached, whereas, in the fragment caching, a part of the web page, such as a user control added to the web page, is cached.

Q4. Make a list of all templates of the repeater control?
Ans. The repeater control contains the following templates:
item template
alternatingitem template
seperatortemplate
header template
footer template

Q5. How can you assign page attributes in an ASP.NET application?
Ans. The @page directive is responsible for this.

Q6. Which method is used to post a web page to another web page?
Ans. The response.redirect method is used to post a page to another page, as shown in the following code snippet:
response.redirect("destinationpagename.aspx");

Q7. What is a cookie?
Ans. Cookie is a lightweight executable program, which the server posts to client machines. Cookies store the identity of a user of a user first visits of the web site & validation them later on the next visit for their authenticity.

Q8. What are the custom user controls in ASP.NET?
Ans. The custom user controls are the controls that defined by developers. These controls are the mixture of custom behavior. These controls work similar to other web server controls.

Q9. What does the .webpart file do?
Ans. The webpart file explains the setting of a web parts control that can be included to a specified zone on a web page.
  
Q10. How can you identify that the page is postback?
Ans. The page object uses the Ispostback property to check whether the page is posted back or not. If the page is postback, this property is set to true.

Q11. What is .NET reflector?
Ans. .NET reflector is a software utility for Microsoft .net combining class browsing, static analysis & decompilation.

Q12.What is the difference between globalization & localization?
Ans. GLOBALISATION is the process of making your application cultureagonostic.
         LOCALISATION is the process of adding translation & doing whatever else it takes to make your    application actually work for a specific & local.

Q13.What is the difference between an exe & a dll?
Ans. An exe is an executable program. An dll is a library that contains code & data that can be used by more than one program at the same time.

Q14.What is the Gac?
Ans. Gac stands for global assembly cache. It is a central repository for strongly named .net assemblies and helps prevent dll hell.

Q15. What is mono?
Ans. Mono is an open source, cross platform implementation of c# & the CLR that is binary compatible with Microsoft.



Download this article as PDF 

 

Tuesday 2 October 2012

Some Questions On .Net #2


Q1.How does you sign-out from forms authentication?
Ans. The forms authentication.signout() method is used to sign-out from  the forms authentication.

Q2. What is the auto postback?
Ans. If you want to postback automatically when an event is raised, you need to set the autopostback property of the control to true.

Q3. What is the function of the viewstate property?
Ans. The ASP.NET 4.0 introduced a new property called viewstatemode for the control class. Now you can enable the viewstate to an individual control even if the view state for an asp.net page is disabled.

Q4. Why do you use the app_code folder in asp.net?
Ans. The app_code folder is automatically present in the project. It stores the files, such as classes, typed data set, text files & reports. If this folder is not available in the application, you can add this folder.

Q5. Define a multilingual web site?
Ans. A multilingual web site serves content in a number of languages. It contains multiple copies for its content and other resources, such as date & time in different languages.

Q6. What is an asp.net web form?
Ans. ASP.NET web forms are designed to use controls & features that are almost as powerful as the ones used with windows forms, & so they are called as web forms.

Q7. How can you display all validation messages in one control?
Ans. The validation summary controls display all validation messages in one control.

Q8.Which two new properties are added in ASP.NET 4.0 page class?
Ans. The two new properties added in the page class are metakeyword & metadescription.

Q9.How can you register a custom server control to a web page?
Ans. You can register a custom server control to web page using the @register directive.

Q10. Which ASP.NET objects encapsulate the state of the client & the browser?
Ans. The session objects encapsulate the state of the client & browser.    





Monday 1 October 2012

Some Questions On .Net #1


Q1. What is ASP?
Ans. Active Server Pages (ASP), also known as classic ASP, is a Microsoft's server-side technology, which helps in creating dynamic and user friendly web pages.

Q2. What is ASP.net?
Ans. ASP.net is a specification developed by Microsoft to create dynamic web application, web sites & web services. It is a part of .net framework.

Q3. In which events are the controls fully loaded?
Ans. Page load events guarantees that all controls are fully loaded. Controls are also accessed in page_Init events but you will see that view state is not fully loaded during this event.

Q4. How can we identify that the page is post back?
Ans. Page object has an "Ispostback" property, which can be checked to know that is the page posted back.

Q5. What is the lifespan for items stored in viewstate?
Ans. The items stored in viewstate live until the lifetime of the current page expires including the postback to the same page.

Q6. How information about the user's locale can be accessed?
Ans. The information regarding a user's locale can be accessed by using the system.web .ui.page.culture property.

Q7. What is the difference between SQL notification & SQL invalidation?
Ans. The SQL cache notification generates notification when the  data of a database changes, on which your cache item depends . the SQL cache invalidation makes a cached
item invalid  when the data stored in a SQL server database changes.

Q8. Which is the parent class is the web server control?
Ans. The system.web.ui.control class is the parent class for all web server controls.

Q9. Can you set which type of comparison you want to perform by the compare validator control?
Ans. Yes, by setting the operator property of the compare validator control.

Q10.What is the behavior of web browser when it receives an invalid element?
Ans. The behavior of a web browser when it receives invalid elements depends on the browser that you use to browse your application. Most of the browsers ignore the invalid element, whereas, some of them display the invalid elements on the page.


Download this article in pdf format.