Posts

Showing posts from February, 2025

File Handling

  # File Handling:- There are 2 type of file 1.  User files 2.  System files FILE Properties(Modes) :- * open save read delete write. * In c# the I/O libarires is used for file handling. # File handling object:- ·  FileStream object.:-  Stream is a sequence of cell. ·  StreamWriter object. :- Using cell ·  StreamReader object. :- Read Data from file. ·  TextWriter object. ·  TextReader object.  

C# Generic

  * C# Generic : - 1. It is a special type of method accepting random parameters. 2. Generic is repretesend in angle bracket <>. 3. Generric parameteric is used as Capital T operator. 4. There are two implementation in generic concept. A. Generic class B. Generic   method Prog; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks;   namespace proggenericclasss {     class genericclass < T >     {         public genericclass(T MSG)         {             Console.WriteLine(MSG);           }     }     class Program     {         static void Main( string [] args)  ...

EXCEPTION in c#

  #EXCEPTION :- 1. Exception is returning logically error . 2. There are following types of exception used in c# programming that are listed below. 3. All types of exception are stored in exception class.   A. Try Catch B. Finally C. Throw D. User define exception.   A. Try catch :- 1. TRY:- It represented the program logic . 2. CATCH :- It return the logical exception. Progrm:- using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks;   namespace progexcepetion2 {     class Program     {         void input( int a , int b)         {             int c;             try             {  ...

Hash table, ShortedList , Namespace

  1. Hash table - It is used to store data in particular key. . Hash table display data in random format. Prog using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Collections;     namespace proghashtb {     class Program     {         static void Main( string [] args)         {             Hashtable h1 = new Hashtable();             // insert element in hashtable             h1.Add( "101" , "nagpur" );             h1.Add( "102" , "pune" );             h1.Add( "103" , "mumbai"...