Documente Academic
Documente Profesional
Documente Cultură
Interface
· An abstract class may contain complete or incomplete methods. Interfaces can contain only
the signature of a method but no body. Thus an abstract class can implement methods but an
interface cannot implement methods.
· An abstract class can contain fields, constructors, or destructors and implement properties. An
interface cannot contain fields, constructors, or destructors and it has only the property's
signature but no implementation.
· An abstract class cannot support multiple inheritances, but an interface can support multiple
inheritance. Thus a class may inherit several interfaces but only one abstract class.
· A class implementing an interface has to implement all the methods of the interface, but the
same is not required in the case of an abstract Class.
· Various access modifiers such as abstract, protected, internal, public, virtual, etc. are useful in
abstract Classes but not in interfaces.
· Abstract classes are faster than interfaces.
====================================================
VARCHAR[(n)]
Null-terminated Unicode character string of length n,
with a maximum of 255 characters. If n is not supplied, then 1 is assumed.
8000 (maximum length)
=======================================
To add a sub-report right click on the current report's "Details" section and select "Insert ->
Section"
In the "Insert Section" window select "Details" and click the "Insert" button at the top of the
screen.
This will add a separate "Details" section as shown below.
Click on the "OK" button to finish adding the section. When you are finished you will see a
new section added to the report.
Now, you need to add a sub-report inside the "DetailSection2(Details b)." Right click inside
the Details b section and select "Insert -> Sub-Report" as shown in the screenshot below.
When you select the sub-report option it will create a rectangle where the sub report will be
displayed. Simply place the sub-report rectangle inside the "Details b" section. This will
open an insert Sub-Report window.
=======================================================
To create formula field to display the Quarter of the SalesDate. Right click on the Formula
Fields node in the Field Explorer and select New… from the pop-up menu. Enter Quarter for
the formula name and click the Use Editor button.
This formula will create a variable to hold the running total of any sales that occurred in
quarter 1. Variables have three options for scope: Local, Global, or Shared. Local means
that the variable is used in the specific function and its value is lost once the formula exits.
Global means that the variable will retain its value even after the function exits and can be
used in other formulas in the report. Shared means you can use this variable in other
formulas or even sub reports. By default if you omit the scope of a variable it is Global.
=================================================
There are two ways we can use cross page postsbacks in ASP.NET
1st method
In this i've created a Default.aspx page with two textbox and one button , button click will
post back to Default2.aspx and there we will retrieve and show values of both textboxes
Now to retrieve values of textBoxes on Default2.aspx page, write below mentioned code in
Page_Load event of second page (Default2.aspx)
C# code behind
protected void Page_Load(object sender, EventArgs e)
{
//Check whether previous page is cross page post back or not
if (PreviousPage != null && PreviousPage.IsCrossPagePostBack)
{
TextBox txtPbFirstName = (TextBox)PreviousPage.FindControl("txtFirstName");
TextBox txtPbLastName = (TextBox)PreviousPage.FindControl("txtLastName");
Label1.Text = "Welcome " + txtPbFirstName.Text + " " + txtPbLastName.Text;
}
else
{
Response.Redirect("Default.aspx");
}
}