All java c# asp.net .net servlet jdbc c sqlserver android ado.net javascript php wcf clearcase angularjs 2

What is row command event? When we will go for row command event?

Row Command event is one of the events of the Gridview control. This event will fire when user will click any button within the Gridview control.

The RowCommand Event can be used to get the selected GridView Row value or text.The RowCommand event is raised when a button is clicked in the gridview control. This enables you to provide an event-handling method that performs a custom routine whenever this event occurs.

The RowCommand Event occurs when a button is clicked in a GridView control.

<asp:GridView OnRowCommand="GridViewCommandEventHandler" /> 
The RowCommand event is raised when a button is clicked in the GridView control. This enables you to provide an event-handling method that performs a custom routine whenever this event occurs.

What is returnurl?

returnurl is querystring varible

 when the page remains unused for a certain time, the session expires and the user is redirected to the login page. returnurl has the url of the original page. Normally, myloginform.aspx should be your first page the user see.

What is Hiddenfield and what is the scope?

1. HiddenField is a Server side control, which can hold the user data but holding the data will not be visible because it is a INVISIBLE CONTROL. 2. To Implement HiddenField we can use Asp.Net server control called HiddenField.

The HiddenField control is used to store a value that needs to be persisted across posts to the server. It is rendered as an <input type= "hidden"/> element. Normally view state, session state, and cookies are used to maintain the state of a Web Forms page. However, if these methods are disabled or are not available, you can use the HiddenField control to store state values. Note that because the value of a HiddenField is rendered to the client browser, it is not suitable for storing security-sensitive values. To specify the value for HiddenField a control, use the Value property.

Scope:

A hidden field does not render visibly in the browser, but you can set its properties just as you can with a standard control. When a page is submitted to the server, the content of a hidden field is sent in the HTTP Form collection along with the values of other controls. A hidden field acts as a repository for any page-specific information that you would like to store directly in the page. Hidden field stores a single variable in its value property and must be explicitly added it to the page.ASP.NET provides the HtmlInputHidden control that offers hidden field functionality. 

What is the Difference between Cookie and Session?

COOKIE

SESSION

  • Session - server side state management technique.

  • Cookie is a variable which will create within the client machine.

  • Session is also a variable which will create within the Web server.

  • Default timeout of a cookie is 30 minutes.
  • Default life time of session variable is 20 minutes.

A cookie is a bit of data stored by the browser and sent to the server with every request.

A session is a collection of data stored on the server and associated with a given user (usually via a cookie containing an id code)

The main difference between a session and acookie is that session data is stored on the server, whereas cookies store data in the visitor's browser.Sessions are more secure than cookies as it is stored in server.Cookie can be turn off from browser.

Can we convert server side control as client side control?

We cannot convert server side control as client side control.

Yes you can control it using SSH.
See the below link for your reference.

Getting Started with SSH

Why inproc session is not suitable for webgarden and webfarm model?

Inproc sessions will create within the current App Domain due to that reason app domain data is not sharable due to that reason Inproc sessions are not suitable for WEB GARDEN and WEBFARM MODELS.

InProc mode, which stores session state in memory on the Web server. This is the default.

What is Boxing and Unboxing?

BOXINGUNBOXING
  • It is the process of converting from VALUE type to REFERENCE type.
  • It is the process of converting from REFERENCE type to VALUE type.
  • Ex: converting from int to object
  • EX: converting from object to int.

BOXING:

Implicit conversion of a value type (int, char etc.) to a reference type (object), is known as Boxing. In boxing process, a value type is being allocated on the heap rather than the stack.

UNBOXING:

Explicit conversion of same reference type (which is being created by boxing process); back to a value type is known as unboxing. In unboxing process, boxed value type is unboxed from the heap and assigned to a value type which is being allocated on the stack.

NOTE:

Sometimes boxing is necessary, but you should avoided it if possible, since it will slow down the performance and increase memory requirements.

Converting value type to reference type is boxing and Converting Reference type to value type is Unboxing

What is Error, Bug and Defect?

Errors -> which comes at the time of development.

Bug -> which comes at the time of testing. (Pre-Release)

Defect --> Which comes in Production. (Post-Release)

A mistake in coding is called error ,error found by tester is called defect,  defect accepted by development team then it is called bug ,

Bug:
The software product has some malfunctioning code, and the malfunction is not identified or discovered by the developer. The malfunction is called Bug.
The bug is always passive. 
Defect accepted by development team then it is called bug.

Defect:
When the software is used by customers the malfunctioning code might generate unexpected results. 
In other words, the passive bug becomes active and results in Defect.
Variance between Expected and Actual Result .
Error found by tester is called defect.
Defect is when this mistake is present in the component or application.

Error:
Error is deviation from actual and expected value.
Mistake done by the developer . which may syntactical error or Logical error .
A mistake in coding is called error.

Simply

Error: A discrepancy between a computed, observed, or measured value or condition and the true, specified, or theoretically correct value or condition. This can be a misunderstanding of the internal state of the software, an oversight in terms of memory management, confusion about the proper way to calculate a value, etc.

Failure: The inability of a system or component to perform its required functions within specified performance requirements. See: bug, crash, exception, and fault.

Bug: A fault in a program which causes the program to perform in an unintended or unanticipated manner. See: anomaly, defect, error, exception, and fault. Bug is terminology of Tester.

Fault: An incorrect step, process, or data definition in a computer program which causes the program to perform in an unintended or unanticipated manner. See: bug, defect, error, exception.

Defect:Commonly refers to several troubles with the software products, with its external behavior or with its internal features.

What is the difference between bug and defect?

- A bug is getting a problem at the time of testing, where as a defect is problem that got by the customer in production time.
- A bug is a fault in a program which causes it to behave abruptly. Bugs are usually found either during unit testing done by developer of module testing by testers.
- A defect is found when the application does not conform to the requirement specification. A defect can also be found when the client or user is testing.

How to add and remove data to Application State Variables?

/Code to add data to Application State
Application.Add("AppName", "Sample");

 //Code to remove all Application State Variables data
Application.RemoveAll();

//Code to add data to Application State,Application.Add(“AppName”, “Sample”);//Code to remove data from Application State,Application.Remove(“AppName”);

What is the importance of foreign key?

  1. To establish relation between Parent table and Child table we require a common column , that column should be parent table primary key column.
  2. To make that relation strong we require Foreign key constraint that means Foreign key constraint we should assign child table common column.

A foreign key is a value in a column that relates to a column of another table in the database. This is a fundamental concept in a relational database; the FK is the way rows of tables are joined to each other. There are several advantages to formally defining a foreign key:

1. The relationship between the related tables is clearly documented

2. The relationship between the related tables can be enforced by the database. That is, if the value specified by the FK does not exist in the foreign table, then the insert or update can be prevented. This is known as referential integrity. Likewise, deletion of a row of the foreign table can be prevented if a FK value exists in the related table.

  1. As a constraint on the table to stop you inserting something that doesn't point to anything;
  2. As a clue for the optimizer; and
  3. For historical reasons where is was more needed.