.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
david stephan

Home >> Interview Question >> .NET Framework >> Post New Question Subscribe to Interview Questions

What are the different state management techniques used in asp.net for web applications?

Posted By :Gowthammanju     Posted Date :July 31, 2011    Points :40   Category :.NET Framework 
In ASP.Net the state can be maintained in following ways
Server-side state management
Application objects
Session Variables
Database
Client-side state management
Cookies
Hidden input fields
Query String
ViewState

You can also find related Interview Question to What are the different state management techniques used in asp.net for web applications?  below: 

what are the different state management techniques in ASP.Net?

  
Asp.Net state management can be maintained in two ways as below
Client- Side State Management
ASP.Net provides following techniques to store state information. This will improve application performance by minimizing server resource utilization
1.View state
2. Hidden Fields
3. Cookies
4. Query Strings
Server - Side State Management
With respect to Server Side State Management ASP.Net uses "Application state" and "Session state" objects to store data or user state.

Read more: asp.net interview questions and answers | Introduction | FreeJobAlert.com http://www.freejobalert.com/explain-the-advantages- (More...)

how to pass the values across webforms without using State Management Concepts:

  
Page1.aspx.cs

public String CurrentCity
{
get
{
return TextBox1.Text;
}
}


In Page2.aspx

<%@ PreviousPageType VirtualPath="~/Page1.aspx" %>

Label1.Text=PreviousPage.CurrentCity;


Another Method:

In Page2.aspx

TextBox SourceTextBox = (TextBox)PreviousPage.FindControl("TextBox1");

Label1.Text = SourceTextBox.Text;




(More...)

What is Profile Based State in ASP State Management ?

  
A profile based state is nothing but the state changes is saved permanently for a particular profile. That means the state is saved manually by the user. If there was no saving done the Default settings will be applied .


For Example .
If we login into igoogle.com, there if we have our customized page set once, untill and unless we change it delibrately it will be the same page. (More...)

State Management in ASP.NET

  
State Management
Type of state management in ASP.NET
1.InProc(Where session objects stored wit in IIS server)
2.OutProc(Where session objects store out of the server
a.State Server(where session objects can store in different server)
b.SQL server(where session objects can store in SQL server)

This can be configure in web.config file . (More...)

What are the client-side state management technique supported by ASP.NET?

  
Control state

View state

Cookies

Hidden fields

Query strings (More...)

What options are available to deploy my .NET applications?

  
The .NET Framework simplifies deployment by making zero-impact install and XCOPY deployment of applications feasible. Because all requests are resolved first to the private application directory, simply copying an application's directory files to disk is all that is needed to run the application. No registration is required.
This scenario is particularly compelling for Web applications, Web Services, and self-contained desktop applications. However, there are scenarios where XCOPY is not sufficient as a distribution mechanism. An example is when the application has little private code and relies on the availability of shared assemblies, or when the application is not locally installed (but rather downloaded on demand). For these cases, the .NET Framework provides extensive code download services and integration with the Windows Installer. The code download support provided by the .NET Framework offers several advantages over current platforms, including incremental download, code access security (no more Authenticode dialogs), and application isolation (code downloaded on behalf of one application doesn't affect other applications). The Windows Installer is another powerful deployment mechanism available to .NET applications. All of the features of Windows Installer, including publishing, advertisement, and application repair will be available to .NET applications in Windows Installer 1.5. (More...)

Describe the techniques for optimising your application?

  
. Avoid round-trips to server. Perform validation on client.
. Save viewstate only when necessary.
. Employ caching.
. Leave buffering on unless there is a dire need to disable it.
. Use connection pooling.
. Use stored procedures instead of in-line SQL or dynamic SQL. (More...)

Session state vs View state

  
In some cases, using view state is not feasible. The alternative for view state is session state. Session state is employed under the following situations:
. Large amounts of data - View state tends to increase the size of both the HTML page sent to the browser and the size of form posted back. Hence session state is used.
. Secure data - Though the view state data is encoded and may be encrypted, it is better and secure if no sensitive data is sent to the client. Thus, session state is a more secure option.
. Problems in serializing of objects into view state - View state is efficient for a small set of data. Other types like DataSet are slower and can generate a very large view state (More...)

Is IIS require to run asp.net Web applications?

  
If you are using Visual Studio, you can use the ASP.NET Development Server built into Visual Studio to test your pages. The server functions as a local Web server, running ASP.NET Web pages in a manner virtually identical to how they run in IIS. To deploy a Web application, you need to copy it to a computer running IIS version 5 or 6. (More...)

What is Automatic Memory Management in ASP.NET?

  
Automatic Memory Management: From a programmer's perspective, this is probably the single biggest benefit of the .NET Framework. No, I'm not kidding. Every project I've worked on in my long career of DOS and Windows development has suffered at some point from memory management issues. Proper memory management is hard. Even very good programmers have difficulty with it. It's entirely too easy for a small mistake to cause a program to chew up memory and crash, sometimes bringing the operating system to a screeching halt in the process.

Programmers understand that they're responsible for releasing any memory that they allocate, but they're not very good at actually doing it. In addition, functions that allocate memory as a side effect abound in the Windows API and in the C runtime library. It's nearly impossible for a programmer to know all of the rules. Even when the programmer follows the rules, a small memory leak in a support library can cause big problems if called enough.

The .NET Framework solves the memory management problems by implementing a garbage collector that can keep track of allocated memory references and release the memory when it is no longer referenced. A large part of what makes this possible is the blazing speed of today's processors. When you're running a 2 GHz machine, it's easy to spare a few cycles for memory management. Not that the garbage collector takes a huge number of cycles--it's incredibly efficient.
The garbage collector isn't perfect and it doesn't solve the problem of mis-managing other scarce resources (file handles, for example), but it relieves programmers from having to worry about a huge source of bugs that trips almost everybody up in other programming environments.
On balance, automatic memory management is a huge win in almost every situation. (More...)

What is the role of the ScriptManager control in implementing multilingual applications (AJAX)?

  
The ScriptManager control can be used to define the UI or custom UI cultures that you would use in your applications. You can set the
EnableScriptLocalization and EnableScriptGlobalization properties of
the ScriptManager control to true and specify the script reference path as per your requirements. (More...)

Quick Links For Interview Questions Categories:
ASP.Net Windows Application   .NET Framework   C#   VB.Net   ADO.Net  
Sql Server   SharePoint   Silverlight   OOPs   JQuery   JavaScript/VBScript
Biztalk Patten/Practices .IIS WCF WPF WWF
Networking Aptitude Others   All      

Find questions, FAQ's and their answers related to .NET, C#, Vb.Net, Sql Server and many more.

 
Now you can find lots of .NET, C#, Vb.Net, SQL Server,Windows, ASP.Net related Questions and their Answers here at www.dotnetspark.com. Our aim is to help you pass your certification Exams (MCP, MCSD, MCAD etc.,) with flying scores and get good name in your company.

So, Start looking our Interview Question section daily and improve your .NET Skills. You can also help others by posting Interview Questions and their Answers in this section.


Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend