You are here:   HomeC# Programming
by Dinesh Thakur Category: Advanced C#

An attribute is a declarative tag, which can be used to provide information to the runtime about the behavior of elements of application such as classes and assemblies.

 

Attributes are used to give extra information to the .NET compiler. C# and the .NET framework have a few built-in attribute types, but it is also possible to create new ones by extending the system Attribute class. Below we describe a few common uses of attributes.



 
by Dinesh Thakur Category: Advanced C#

Property is a feature to add more smartness to data fields for get and set the value.

Properties are named members of classes, structs and interfaces. They provide a flexible mechanism to read, write, or compute the values of private fields through accessors. Properties can be thought of as virtual fields. From the outside, a class' property looks just like a field. But from the inside, the property is generated using the actual class fields.

 
by Dinesh Thakur Category: Advanced C#

Application development as the name suggest is a development process. With time, new functionality is added to current applications and hence different versions of the application come to existence. Application development for quite sometime has been focused towards component oriented development. Hence an upgrade of the application definitely means an upgrade of the components. These components need to be versioned along with the application. Often components alone can face an upgrade-offering new functionality. When this happens, existing clients face a problem when the component they reference is upgraded. Net assemblies attempt to solve this problem by embedding the version information into the assembly itself. With the advanced capabilities of Windows 2000, two different assemblies can be loaded into the memory side-by-side.



 
by Dinesh Thakur Category: C# Libraries

Like java, C# also provides built-in support for multithreading. A multithread program contains two or more parts that can run concurrently. Each part of such program is called thread, and each thread defines a separate path of execution. Thus, multithreading is a specialized form of multitasking.



 
by Dinesh Thakur Category: C# Libraries

Console Input

The Console class allows using the Write () and the WriteLine () functions to display things on the screen. While the Console.Write () method is used to display something on the screen, the Console class provides the Read () method to get a value from the user. To use it, the name of a variable can be assigned to it. The syntax used is:

 
by Dinesh Thakur Category: C# Libraries

Files are the great way to store data between instances of your application, or file can be used to transfer data between applications. All input and output in the .NET framework involve the abstract base class Stream. The Stream class supports reading and writing bytes. Stream integrates asynchronous support. Its default implementations define synchronous reads and writes in terms of their corresponding asynchronous methods, and vice versa.

 
by Dinesh Thakur Category: C# Libraries

There are no exceptions in C arid in C++ one can get away from using them with error handling functions such as exit() and terminate(). In C# these functions are absent and we introduce exceptions which take their place. The exception handling in C#, and Java is quite similar.



 
by Dinesh Thakur Category: Windows Application in C#

Web Forms consist of a combination of HTML, code, and controls that execute on a Web server that i's running Microsoft Internet Information Services (lIS). Web Forms display a UI by generating HTML that is sent to the browser, while the supporting code and controls that run the UI stay on the Web server. This split between client-side interface and server-side code is a crucial difference between Web Forms and traditional Web pages. While a traditional Web page requires all of the code to be sent to ahd be processed at the Browser, Web Forms need to send only the interface controls to the browser ,and the page processing is kept on the server. This UI/code split increases the range of supported browsers while increasing the security and functionality of the Web page.



 
by Dinesh Thakur Category: Windows Application in C#

When the client requests a Web page for the first time, the following set of events take place:

 

1. The client browser issues· a GET HTTP request to the server.

2. The ASP.NET parser interprets the source code.

3. If the code was not already compiled into a dynamic-link library (DLL), ASP.NET invokes the compiler.

4. Runtime loads and executes the Microsoft intermediate language (MSIL) code.

                                 ASP.NET EXECUTION MODEL . 

When the user requests the same Web page for the second time, the following set of events take place:

1. The client browser issues a GET HTTP request to the server.

2. Runtime loads and immediately executes the MSIL code that was already compiled during the user's first access attempt.

 
by Dinesh Thakur Category: Windows Application in C#

The foundation of most solutions that involve Windows Forms is the Windows Application project. Creating one is easy within the integrated development environment (IDE).

 

Page 5 of 6



Subscribe To Free Daily Newsletter!

Get Free News Updates Delivered Directly To Your Inbox
About Dinesh Thakur

Dinesh ThakurDinesh Thakur holds an B.SC (Computer Science), MCSE, MCDBA, CCNA, CCNP, A+, SCJP certifications. Dinesh authors the hugely popular Computer Notes blog. Where he writes how-to guides around Computer fundamental , computer software, Computer programming, and web apps. For any type of query or something that you think is missing, please feel free to contact us.



What's New and Popular





Search Content







Advance Courses



Basic Courses



Advertise with Us