The Highest Post

Related Topics
  • What is the difference between Entity Framework and ADO.NET?
  • What is the difference between Entity Framework and LINQ to SQL?
  • What are the components of Entity Framework Architecture?
  • What are the parts of Entity Data Model (EDM)?
  • What does .edmx consists of?
  • What is LINQ to Entities? What is Entity SQL? What is the role of Entity Client Data Provider?
  • What is the meaning of Pluralize and Singularize in Entity Framework?
  • What is DB Context ?
  • Mention what is DataAdapter class in ADO.NET?
  • How can we handle concurrency in Entity Framework?
  • What is client wins and store wins mode in Entity Framework concurrency?
  • What are the development approaches are supported in Entity Framework?
  • How many types of inheritance are supported by Entity Framework?
  • What is difference between Code First and Model first approach ?
  • When will you prefer to use Code First or DB First approach and why?
  • What is the difference between lazy loading and eager loading?
  • What is difference between Code First and Model first approach ?
  • What's the use of Response.Output.Write()?
  • In which event of page cycle is the ViewState available?
  • What is the difference between Server.Transfer and Response.Redirect?
  • From which base class all Web Forms are inherited?
  • What is ViewState?
  • What is ViewState?
  • Where the viewstate is stored after the page postback?
  • How long the items in ViewState exists?
  • What are the different Session state management options available in ASP.NET?
  • What are the different Session state management options available in ASP.NET?
  • What is caching?
  • What are the different types of caching?
  • Which type if caching will be used if we want to cache the portion of a page instead of whole page?
  • Is it possible to create web application with both webforms and mvc?
  • What is Protected Configuration?
  • How can we prevent browser from caching an ASPX page?
  • What is the good practice to implement validations in aspx page?
  • Which protocol is used to call a Web service?
  • Can we have multiple web config files for an asp.net application?
  • What is the difference between web config and machine config?
  • Explain role based security ?
  • What is Cross Page Posting?
  • What is RedirectPermanent in ASP.Net?
  • Explain the working of passport authentication.
  • What are the asp.net Security Controls?
  • In which event are the controls fully loaded?
  • Differentiate strong typing and weak typing
  • How we can force all the validation controls to run?
  • List all templates of the Repeater control.
  • List the major built-in objects in ASP.NET?
  • Which data type does the RangeValidator control support?
  • What is the difference between an HtmlInputCheckBox control and an HtmlInputRadioButton control?
  • Which namespaces are necessary to create a localized application?
  • What are the different types of cookies in ASP.NET?
  • What is the file extension of web service?
  • What are the components of ADO.NET?
  • What is the difference between ExecuteScalar and ExecuteNonQuery?
  • The HTTP protocol on which all web applications work is
  • Explain the application event handlers in ASP.NET ?
  • What is Global Assembly Cache ?
  • Explain the Server Control Events of ASP.NET ?
  • What are Strong Names ?
  • Explain the steps to generate the strong name ?
  • Explain the concept of Globalization and Localization?
  • What is the difference between Authentication and Authorization?
  • What are the various ways of authentication techniques in ASP.NET?
  • There are basically three types of authentication modes in ASP.NET –
  • What does AspCompat="true" mean and when should you use it?
  • What are HttpHandlers?
  • What is User Control in ASP.NET?
  • What’s a bubbled event?
  • In which event, controls will be fully loaded?
  • What is the difference between a default skin and a named skin?
  • What you mean by Query String? What are its advantages and limitations?
  • What is smart navigation?
  • What is tracing? Where is it used?
  • What are modes of Session state in ASP.NET?
  • List all different typesS of directives in .NET?
  • What is .Net Remoting?
  • What is Application Domain?
  • In ASP.NET how many navigation controls are there?
  • What is Delay signing?
  • ) What are server-side comments?
  • What are the common properties of all validation controls?
  • hat is cross-page posting?
  • What are the best ways to send data across pages in ASP.NET?
  • What are Web Part controls in ASP.NET?
  • What’s the difference between Literal control and Label control?
  • Explain the components of web form in ASP.NET?
  • Which are the different IIS isolation levels in ASP.NET?
  • How to open a page in a new window?
  • What is a component?
  • How do I sign out in forms authentication?
  • What are design patterns?
  • Why PDB files are useful?
  • How we can handle SQL Exceptions in ASP.NET?
  • How to set maximum length of Textbox in ASP.NET?
  • What is the difference between Web Services and Remoting?
  • Advantages of Entity Framework?
  • Disadvantages of Entity Framework?
  • Entity Framework Top questions

    Find by name:


    New Post

    Recent Post

  • Cara Brown What is the difference between Entity Framework and ADO.NET?

    Entity Framework will be around the ADO.NET, which means ADO.NET is faster than Entity Framework. Ado.net needs to write so much code to talk to database but Entity Framework will talk to database without much code involved. Entity Framework Performance is not good compared to ADO.NET.

    Cara Brown What is the difference between Entity Framework and LINQ to SQL?

    Entity Framework: "Supports databases like SQL, MySQL, DB2 etc. Allows one-to-one, one-to-many & many-to-many mappings between the Entity classes and the relational tables. Relationships are maintained in 3 different files - .csdl, .msl and .ssdl. Supports Complex Types. Supports Rapid application development with SQL Server, DB2, MySQL etc. LINQ to SQL: Supports only for SQL database. Allows only one-to-one mapping between the entity classes and the relational tables. .dbml file is generated for maintaining the relationships. No Support for Complex Types. Supports Rapid application development with SQL Server.

    Jay Man What are the components of Entity Framework Architecture?

    • Entity Data Model (EDM), LINQ to Entities, Entity SQL, Object Service, Entity Client, Data Provider, ADO.Net Data Provider.

    Jay Man What are the parts of Entity Data Model (EDM)?

    • Conceptual Model, Mapping, Storage Model.

    Jacob Bosh What does .edmx consists of?

    .edmx file is a XML file and it has Conceptual Model, Storage Model and Mapping details i.e, SSDL (Store schema definition language), CSDL (Conceptual schema definition language), MSL (Mapping specification language). Conceptual Models are the model classes which contain the relationships. These are independent of the database design. Storage Models are our database design models, which contains database tables, views, stored procs and keys with relationships. The Mapping will have the information on how the Conceptual Models are mapped to Storage Models.

    Peter Agyekum What is LINQ to Entities? What is Entity SQL? What is the role of Entity Client Data Provider?

    LINQ to Entities is a query language which we used to write queries against the object models and the query result will return the entities defined in the Conceptual Model. Entity SQL is a query language is like LINQ to Entities. This is a bit complex compared to LINQ to Entities. A developer who is using this should learn this separately. Responsibility of Entity Client Data Provider is to convert the LINQ to Entities or Entity SQL queries to a SQL query, which is understood by the underlying database. This finally communicates with ADO.NET Data Provider which in turn used to talk to the database.

    Peter Agyekum What is the meaning of Pluralize and Singularize in Entity Framework?

    Pluralize and Singularize gives the meaningful naming conventions for objects. We will get this option while adding an edmx file. On selecting this option Entity Framework will adhere to Singular or Plural coding conventions.

    Peter Agyekum What is DB Context ?

    When we create a edmx file, it will have the list of entities and context class which will be derived from DB Context class.

    Joseph Fredie Mention what is DataAdapter class in ADO.NET?

    In ADO.NET data-adapter class fetch data from the database, stores data in a dataset and reflects the changes made in the dataset to the database. For all type of communication, data-adapter act as an intermediary. Using the Fill() method, data-adapter fills data to a Data-table.

    Joseph Fredie How can we handle concurrency in Entity Framework?

    Note: Before this question, the interviewer can ask you about concurrency and what is pessimistic and optimistic locking. Please do refer to the ADO.NET chapter for those. In EF, concurrency issue is resolved by using optimistic locking. Please refer to the ADO.NET chapter for what is optimistic locking and pessimistic locking? To implement optimistic locking, right click on the EDMX designer and set the concurrency mode to Fixed, as shown in the below figure.

    Joseph Fredie What is client wins and store wins mode in Entity Framework concurrency?

    Client wins and store wins are actions which you would like to take when concurrency happens. In store wins / database wins, the data from the server is loaded into your entity objects. Client wins is opposite to stored wins, data from the entity object is saved to the database. We need to use the Refresh method of the Entity Framework context and provide the RefreshMode enum values. Below is a simple code snippet which executes ClientWins.

    Kai Tran What are the development approaches are supported in Entity Framework?

    Code First Approach – where code defines the database. Entity Framework handles creation. A complete detailed implementation of Entity Framework Code First Approach here. Database First Approach – regular approach used where database is first created or already exists. Model First Approach – where model is drawn first that further generate database scripts.

    Samuel Kodi How many types of inheritance are supported by Entity Framework?

    Entity Framework supports three types of inheritances 1. Table-per-Hierarchy (TPH) 2. Table-per-Concrete-Type (TPC) 3. Table-per-Type (TPT)

    Samuel Kodi What is difference between Code First and Model first approach ?

    In the Code-First approach, When you do not have your database exist and you start creating classes for your domain entity and Context class rather than design your database first and then create the classes which match your database design. In the Model First approach, you create entities, relationship on the visual designer integrated in Visual Studio and then generate entities, context class and database script from your visual model.

    Samuel Kodi When will you prefer to use Code First or DB First approach and why?

    If you have existing database already or you want to build your database first than other parts of the application then DB First approach to be used. If your prime focus is your domain classes and then create the database from your domain classes then Code first approach to be used. This ensures that you will have full control over code.

    Samuel Kodi What is the difference between lazy loading and eager loading?

    Lazy and eager loading are two different ways that Entity will load related data (like the Orders attached to our Customers).     Lazy loading means that when an entity is first read, its related entities are not loaded. Entity Framework waits until you try to access those entities before querying the database again. This can lead to multiple database queries. For instance, the following code will result in two different database queries:

    Peter Agyekum What is difference between Code First and Model first approach ?

    Code First approach : Whether you have an existing database or not, you can code your own classes and properties that correspond to tables and columns and use them with Entity Framework without an .edmx file. In this approach Entity Framework does not leverage any kind of configuration file (.edmx file) to store the database schema, because the mapping API uses these conventions to generate the database schema dynamically at runtime.Code first approach is used to fast development and developer has full controls on entities.Model First approach : We don't have an existing database and the Entity Framework offers a designer that can create a conceptual data model. It also uses an .edmx file to store the model and mapping information. When the model has been created then the Entity Framework designer can generate the database schema that can be used to create the database.

    Peter Agyekum What's the use of Response.Output.Write()?

    We can write formatted output using Response.Output.Write().

    Peter Agyekum In which event of page cycle is the ViewState available?

    After the Init() and before the Page_Load().

    Peter Agyekum What is the difference between Server.Transfer and Response.Redirect?

    In Server.Transfer page processing transfers from one page to the other 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. The clients url history list or current url Server does not update in case of Server.Transfer. Response.Redirect is used to redirect the user's browser to another page or site. It performs 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.

    Peter Agyekum From which base class all Web Forms are inherited?

    Page class.

    Peter Agyekum What is ViewState?

    ViewState is used to retain the state of server-side objects between page post backs.

    Peter Agyekum What is ViewState?

    ViewState is used to retain the state of server-side objects between page post backs.

    Peter Agyekum Where the viewstate is stored after the page postback?

    ViewState is stored in a hidden field on the page at client side. ViewState is transported to the client and back to the server, and is not stored on the server or any other external source.

    Peter Agyekum How long the items in ViewState exists?

    They exist for the life of the current page.

    Peter Agyekum What are the different Session state management options available in ASP.NET?

    In-Process Out-of-Process.

    Peter Agyekum What are the different Session state management options available in ASP.NET?

    In-Process Out-of-Process. In-Process stores the session in memory on the web server. Out-of-Process Session state management stores data in an external server. The external server may be either a SQL Server or a State Server. All objects stored in session are required to be serializable for Out-of-Process state management. 12. How you can add an event handler?

    Peter Agyekum What is caching?

    Caching is a technique used to increase performance by keeping frequently accessed data or files in memory. The request for a cached file/data will be accessed from cache instead of actual location of that file.

    Peter Agyekum What are the different types of caching?

    ASP.NET has 3 kinds of caching : Output Caching, Fragment Caching, Data Caching.

    Peter Agyekum Which type if caching will be used if we want to cache the portion of a page instead of whole page?

    Fragment Caching: It caches the portion of the page generated by the request. For that, we can create user controls with the below code: <%@ OutputCache Duration="120" VaryByParam="CategoryID;SelectedID"%>

    Peter Agyekum Is it possible to create web application with both webforms and mvc?

    Yes. We have to include below mvc assembly references in the web forms application to create hybrid application. System.Web.Mvc System.Web.Razor System.ComponentModel.DataAnnotations

    Peter Agyekum What is Protected Configuration?

    It is a feature used to secure connection string information.

    Peter Agyekum How can we prevent browser from caching an ASPX page?

    We can SetNoStore on HttpCachePolicy object exposed by the Response object's Cache property: Response.Cache.SetNoStore (); Response.Write (DateTime.Now.ToLongTimeString ());

    Peter Agyekum What is the good practice to implement validations in aspx page?

    Client-side validation is the best way to validate data of a web page. It reduces the network traffic and saves server resources.

    Peter Agyekum Which protocol is used to call a Web service?

    HTTP Protocol

    Peter Agyekum Can we have multiple web config files for an asp.net application?

    Yes

    Peter Agyekum What is the difference between web config and machine config?

    Web config file is specific to a web application where as machine config is specific to a machine or server. There can be multiple web config files into an application where as we can have only one machine config file on a server.

    Peter Agyekum Explain role based security ?

    Role Based Security used to implement security based on roles assigned to user groups in the organization. Then we can allow or deny users based on their role in the organization. Windows defines several built-in groups, including Administrators, Users, and Guests.

    Peter Agyekum What is Cross Page Posting?

    When we click submit button on a web page, the page post the data to the same page. The technique in which we post the data to different pages is called Cross Page posting. This can be achieved by setting POSTBACKURL property of the button that causes the postback. Findcontrol method of PreviousPage can be used to get the posted values on the page to which the page has been posted.

    Peter Agyekum What is RedirectPermanent in ASP.Net?

    RedirectPermanent Performs a permanent redirection from the requested URL to the specified URL. Once the redirection is done, it also returns 301 Moved Permanently responses.

    Peter Agyekum Explain the working of passport authentication.

    First of all it checks passport authentication cookie. If the cookie is not available then the application redirects the user to Passport Sign on page. Passport service authenticates the user details on sign on page and if valid then stores the authenticated cookie on client machine and then redirect the user to requested page

    Peter Agyekum What are the asp.net Security Controls?

    Provides a standard login capability that allows the users to enter their credentials Allows you to display the name of the logged-in user Displays whether the user is authenticated or not Provides various login views depending on the selected template email the users their lost password

    Peter Agyekum In which event are the controls fully loaded?

    Page load event.

    Peter Agyekum Differentiate strong typing and weak typing

    In strong typing, the data types of variable are checked at compile time. On the other hand, in case of weak typing the variable data types are checked at runtime. In case of strong typing, there is no chance of compilation error. Scripts use weak typing and hence issues arises at runtime.

    Peter Agyekum How we can force all the validation controls to run?

    The Page.Validate() method is used to force all the validation controls to run and to perform validation.

    Peter Agyekum List all templates of the Repeater control.

    ItemTemplate AlternatingltemTemplate SeparatorTemplate HeaderTemplate FooterTemplate

    Peter Agyekum List the major built-in objects in ASP.NET?

    Application Request Response Server Session Context Trace

    Peter Agyekum Which data type does the RangeValidator control support?

    The data types supported by the RangeValidator control are Integer, Double, String, Currency, and Date.

    Peter Agyekum What is the difference between an HtmlInputCheckBox control and an HtmlInputRadioButton control?

    In HtmlInputCheckBoxcontrol, multiple item selection is possible whereas in HtmlInputRadioButton controls, we can select only single item from the group of items.

    Peter Agyekum Which namespaces are necessary to create a localized application?

    System.Globalization System.Resources

    Peter Agyekum What are the different types of cookies in ASP.NET?

    Session Cookie - Resides on the client machine for a single session until the user does not log out. Persistent Cookie - Resides on a user's machine for a period specified for its expiry, such as 10 days, one month, and never.

    Peter Agyekum What is the file extension of web service?

    Web services have file extension .asmx..

    Peter Agyekum What are the components of ADO.NET?

    The components of ADO.Net are Dataset, Data Reader, Data Adaptor, Command, connection.

    Peter Agyekum What is the difference between ExecuteScalar and ExecuteNonQuery?

    ExecuteScalar returns output value where as ExecuteNonQuery does not return any value but the number of rows affected by the query. ExecuteScalar used for fetching a single value and ExecuteNonQuery used to execute Insert and Update statements.

    Peter Agyekum The HTTP protocol on which all web applications work is

    stateless protocol. By stateless, it just means that information is not retained from one request to another. For instance, if you had a login page which has 2 textboxes, one for the name and the other for the password. When you click the Login button on that page, the application needs to ensure that the username and password get passed onto the next page.

    Peter Agyekum Explain the application event handlers in ASP.NET ?

    Application_Start - Fired when the first user visits a page of the application or first resource is requested from the server. Application_End - Fired when there are no more users of the application. Application_BeginRequest - Fired at the beginning of each request to the server. Application_EndRequest - Fired at the end of each request to the server. Session_Start - Fired when any new user visits. Session_End - Fired when the users stop requesting pages and their session times out.

    Peter Agyekum What is Global Assembly Cache ?

    GAC (Global Assembly Cache) is used to share .NET assemblies. GAC will be used in the below scenarios – If the multiple application wanted to use the same assembly. If the assembly has security requirements. For example, if only administrators have the permission to remove the assembly.

    Peter Agyekum Explain the Server Control Events of ASP.NET ?

    ASP.NET offers many server controls like Textbox, Button Dropdown List etc. Each control will respond to the user’s actions using events and event handler mechanism. Following are the Server Control Events: Postback events - These events sends the web page to the server for processing. Once processing is finished, web page will send data back to the same page on the server. Cached events - These events are processed when a postback event occurs.

    Peter Agyekum What are Strong Names ?

    Strong names are unique names for assemblies. Strong name is similar as GUID in COM components. When we want to deploy the assembly in GAC, then we need to give the strong name for the assemblies. Strong name helps GAC to differentiate between two versions.

    Peter Agyekum Explain the steps to generate the strong name ?

    Go to Visual Studio Command Prompt

    Peter Agyekum Explain the concept of Globalization and Localization?

    Globalization is used to create a multilingual application by defining culture specific features like text, date etc. Localization is used to accommodate the cultural differences in an application.

    Peter Agyekum What is the difference between Authentication and Authorization?

    Authentication is the process in which we are checking the identity of the user to allow the user into the application. So Login is the process of authentication for the application. Now social media authentication is also allowed in many websites to identify the user. Authorization sounds same as authentication but it is different. Authorization handles the permission stuff for the user at web page level. Better example will be if the user is authenticated in the website does not mean that user has full permission on all the pages so that can be controlled by authorization.

    Peter Agyekum What are the various ways of authentication techniques in ASP.NET?

    There are basically three types of authentication modes in ASP.NET – Windows Authentication – windows authentication uses our system credentials for the authentication purpose. Forms Authentication – This is a form based authentication. Login Control in ASP.NET supports this kind of authentication. Passport Authentication - Passport authentication lets you to use Microsoft’s passport service to authenticate users of your application.

    Peter Agyekum There are basically three types of authentication modes in ASP.NET –

    There are basically three types of authentication modes in ASP.NET – Windows Authentication – windows authentication uses our system credentials for the authentication purpose. Forms Authentication – This is a form based authentication. Login Control in ASP.NET supports this kind of authentication. Passport Authentication - Passport authentication lets you to use Microsoft’s passport service to authenticate users of your application.

    Peter Agyekum What does AspCompat="true" mean and when should you use it?

    The AspCompat attribute forces the page to execute in STA mode. ASP.NET runtime throws an exception, if the compatibility tag is omitted and an STA component is referenced in the page. If you convert the STA component to an assembly using Tlbimp.exe, runtime does not detect that the component uses the STA model and does not throw an exception, but the application can suffer from poor performance.

    Peter Agyekum What are HttpHandlers?

    ASP.NET programming supports the creation of custom HttpHandler components, which provide an efficient way to process requests that don't return standard HTML-based pages. E.g. : HttpHandler components are good for situations in which you want to return XML, simple text or binary data to the user. The easiest way to create a custom HttpHandler component is to create a source file with an .ashx extension. You must then add a @WebHandler directive to the top of the .ashx file with a class definition that implements the IHttpHandler interface.

    Peter Agyekum What is User Control in ASP.NET?

    User controls are easy to build, but they are less convenient to use in complicated scenarios. User controls are developed in the same way as we develop Web Forms pages in the visual designer. User controls can handle execution events.

    Peter Agyekum What’s a bubbled event?

    When you have a complex control, like GridView, writing an event processing routine for each object like cell, button, row, etc. is tedious. The controls can bubble up their event handlers, allowing the main GridView event handler to take care of its constituents.

    Peter Agyekum In which event, controls will be fully loaded?

    Page load event guarantees that all controls are fully loaded. Controls are accessed in Page_Init event, but you will see that view state is not fully loaded during this event.

    Peter Agyekum What is the difference between a default skin and a named skin?

    The default skin is applied to all the Web server controls in a Web form and it does not provide a Skin ID attribute. The named skin provides an attribute Skin ID and users have to set the Skin ID property to apply it.

    Peter Agyekum What you mean by Query String? What are its advantages and limitations?

    The Query String helps to send the page information to the server. Advantages of Query String are - All browsers works with Query Strings. Query String would not not require any server resources so it does not exert any sort of burden on the server. Limitations of Query String are - Browser URL does not support many characters and it has limit. Information will be visible to the user, which leads to security issues.

    Peter Agyekum What is smart navigation?

    Using the Page.SmartNavigation property, we can enable smart navigation. When we set the property - Page.SmartNavigation to true, the following features are enabled for smart navigation. Scroll position of a Web page will be maintained after postback. Element which focus on a Web page is maintained during navigation. Most recent Web page state is only retained in the Web browser history folder. Flicker effect which could occur on a Web page during navigation will be minimized.

    Peter Agyekum What is tracing? Where is it used?

    Tracing displays the details about the code execution. It is meant for getting the details of application when it is in running mode, which is really useful for troubleshooting the application. It gives an option to log the details to a file. So from the file it’s easy to figure out the root cause for an issue. .NET supports Trace Listeners, which gets the trace output and it is used to store the information in different places.

    Peter Agyekum What are modes of Session state in ASP.NET?

    In-Process – It stores the session in local system. State Server – It stores the session in a process called “ASP.NET state service”. SQLServer – It stores the session in SQL Server database. Custom – It allows the custom storage provider.

    Peter Agyekum List all different typesS of directives in .NET?

    @Import @Page @Control @Register @Reference @Assembly @OutputCache @Implements

    Peter Agyekum What is .Net Remoting?

    .Net Remoting is considered as the replacement for DCOM. Using .Net remoting remote object calls can be done which lies in different Application domains. As the remote objects runs under different process, client which calls remote object cannot call directly.

    Peter Agyekum What is Application Domain?

    Application Domain is logical boundary created for .NET applications so that one application does not affect the other applications. .NET runtime uses Appdomain as a container for data and code.

    Peter Agyekum In ASP.NET how many navigation controls are there?

    Navigation controls will be used to navigate in a Web application. These controls will store the links either in hierarchical structure or drop-down structure. Navigation controls available in ASP.NET are – Tree View Menu Sitemap Path

    Peter Agyekum What is Delay signing?

    During development process, you will need strong name keys to be exposed to developer which is not a good practice from security point of view. In these situations you can assign the key later on and during development, you can use delay signing.

    Peter Agyekum ) What are server-side comments?

    Server side comments are used in ASP.NET page. This is used to describe the purpose of code snippet. <%--This is how server-side comments can be done -- %> Server side comments always begins with “<%--“ and ends with “-- %>”.

    Peter Agyekum What are the common properties of all validation controls?

    ControlToValidate – control name to be validated. ErrorMessage – error message to be displayed on validation fail. IsValid – Boolean value for checking control’s validation has succeeded or not. Text – displaying the text before validation for validation control.

    Peter Agyekum hat is cross-page posting?

    Server.Transfer() method is used for posting the data from one page to another. In cross page posting, data collected from different pages and will be displayed in single page. So, for doing this we need to set “PostBackUrl” property of the control, in which target page is specified and in target page we can use “PreviousPage” property. For doing this we need to set the directive - @PreviousPageType. Previous page control can be accessed from the method – “FindControl()”.

    Peter Agyekum What are the best ways to send data across pages in ASP.NET?

    Public properties Session

    Peter Agyekum What are Web Part controls in ASP.NET?

    Web part controls are integrated controls which are used to create a website. This allows the user to change the outlook, content and state of the pages in browser.

    Peter Agyekum What’s the difference between Literal control and Label control?

    Label control is rendered as span when rendered as HTML. Label control styles like font size, font color etc can be changed with very less effort. Javascript or JQuery also can access the label control very easily. Literal control rendered as it is. Literal control cannot be styled easily like label control because it does not render in enclosed HTML tags. Javascript or Jquery will not be able to access literal control because while rendering it would not have ID in spite of giving the ID in mark up.

    Peter Agyekum Explain the components of web form in ASP.NET?

    Server controls - The server controls are Hypertext Markup Language (HTML) elements that include a runat=server attribute. These controls provide automatic state management and server-side events and respond to the user events by executing event handler on the server. HTML controls - These controls also respond to the user events but the events processing happen on the client machine. Data controls - Data controls allows us to connect to the database, execute command and retrieve data from database.

    Peter Agyekum Which are the different IIS isolation levels in ASP.NET?

    IIS has three level of isolation – LOW (IIS process) - In this, ASP.NET application and main IIS process run in same process. So, if any application crashes it will adversely affect the others too. Medium (Pooled) - In Medium pooled scenario the IIS and web application run in different process. So in this case there will be two processes process1 and process2. Process1 runs the IIS process and Process2 runs the Web application. High (Isolated) - Here every process runs under it’s own process. This consumes heavy memory but has highest reliability.

    Peter Agyekum How to open a page in a new window?

    To open a page in a new window, we have to use client script using onclick="window.open()" attribute of mainly HTML control.

    Peter Agyekum What is a component?

    Component is a group of classes and methods which are logically related. Component should implement IComponent interface or at least uses class that implemented IComponent interface.

    Peter Agyekum How do I sign out in forms authentication?

    FormsAuthentication.Signout() method is used to sign out.

    Peter Agyekum What are design patterns?

    Creational Design Pattern Abstract Factory Builder Factory Method Singleton Prototype Structural Design Patterns Composite Adapter Flyweight Proxy Decorator Bridge Façade Behavioral Design Patterns Interpreter Iterator Command Observer Mediator Template Method Strategy Chain of Responsibility State Memento Visitor

    Peter Agyekum Why PDB files are useful?

    PDB files are useful for debugging. PDB files contain the debug information and project information. When project is built under Debug mode PDB files are generated and it would not generate in Release mode. These files should not be included in production deployment.

    Peter Agyekum How we can handle SQL Exceptions in ASP.NET?

    We can use try, catch and finally block for error handling. Use SqlException class to handle exceptions specific to SQL Server. try { //some code } catch(SQLException ex) { //Handle SQL Exception }

    Peter Agyekum How to set maximum length of Textbox in ASP.NET?

    Textbox maximum length can be controlled from “MaxLength” property. By default length of the textbox will be 65535.

    Peter Agyekum What is the difference between Web Services and Remoting?

    Both these applications support distributed applications. Remoting is used to talk in binary format and is not cross platform. It expects consumer to be .NET application. It uses SMTP, HTTP and TCP protocols for communication. Web Services can be either WCF or XML Web Services. Web Services are hosted in internet and it is cross platform. Client will be created for using web service and client can consume the methods of web service.

    Peter Agyekum Advantages of Entity Framework?

    The advantages of EF are given bellow: It provides auto generated code It reduce development time It reduce development cost It enables developers to visually design models and mapping of database It provides capability of programming a conceptual model. It provides unique syntax (LINQ / Yoda) for all object queries whether it is database or not It allow multiple conceptual models to mapped to a single storage schema It’s easy to map business objects (with drag & drop tables).

    Peter Agyekum Disadvantages of Entity Framework?

    Lazy loading is the main drawbacks of EF Its syntax is complicated Its logical schema is not able to understand business entities and relation among each other Logical schema of database is not capable of using certain parts of application It is not available for every RDMS Need to handle data in nontraditional way It does not work if we change any schema of the database. We need to update the schema on the solution. It is not good for huge domain model.