Online Programming Solutions
The codingTpoint is cares for the students as well as professionals who aspire to prepare and develop technical skills in web technologies. www.codingtpoint.com
It has been created to provide quality online education to the people... .
codingTpoint is going to launch their blog very soon......😊
Hello Guys....
I have launched a new tutorial websites....for students as well as professional.....On the starting i just put it some tutorial and projects just like c, c++, data structure, html5, css3, javascript.....later on we ll post some more and more content on it.
kindly visit on my site link given below :-
http://codingtpoint.com/
Also U can Subscribe My You-tube Channel Link :-
https://www.youtube.com/channel/UCeU74dNc_06ieA7-g6dyG6A
Thanks & Please Don't Forgot to share with friends 😊
Pick Randomly Any Image....In Asp.Net
----------------------------------------------------------------------------aspx
-------------------------------------------------------------------------
--------------------------------------------------------------------------aspx.cs
--------------------------------------------------------------------------
protected void Page_Load(object sender, EventArgs e)
{
Random r = new Random();
switch (r.Next(5))
{
case 0:
Image1.ImageUrl = "0.png";
break;
case 1:
Image1.ImageUrl = "19.gif";
break;
case 2:
Image1.ImageUrl = "2.gif";
break;
case 3:
Image1.ImageUrl = "21.gif";
break;
case 4:
Image1.ImageUrl = "s.gif";
break;
case 5:
Image1.ImageUrl = "0.png";
break;
}
}
Applying Themes By Changing Background Color In ASP.NET
--------------------------------------------------------------------------aspx Page
-------------------------------------------------------------------------
White
Red
Green
Yellow
Blue
Aqua
Teal
Pink
Orange
---------------------------------------------------------------------------aspx.cs
---------------------------------------------------------------------------
protected void DropDownList1_IndexChanged(object sender, EventArgs e)
{
bg.Style["background-color"] = DropDownList1.SelectedValue;
}
Sorting In Java By Using Pre - Defined Function
---------------------------------------------------------------------
import java.util.*;
class sorting
{
public static void main(String [] args)
{
Scanner s = new Scanner(System.in);
int n,i;
System.out.println("Enter Size...");
n=s.nextInt();
int [] arr=new int[n];
System.out.println("Enter Elements In Array....");
for(i=0; i
Print Multiple Tables By Using Command Line Arguments In Java
------------------------------------------------------------------------------
class table
{
public static void main(String [] args)
{
int a,b,c,d,e;
a=Integer.parseInt(args[0]);
b=Integer.parseInt(args[1]);
c=Integer.parseInt(args[2]);
d=Integer.parseInt(args[3]);
e=Integer.parseInt(args[4]);
for(int i=1; i
Addition Of Two Number By Using Generic Class & Command Line Arguments....in Java!!
---------------------------------------------------------------------------------
class num
{
n a;
p t;
public num(n x,p z)
{
a=x;
t=z;
}
public n show()
{
return a;
}
public p show1()
{
return t;
}
}
class Imp
{
public static void main(String [] args)
{
int n=Integer.parseInt(args[0]);
int p=Integer.parseInt(args[1]);
num ob=new num(n,p);
int c=n+p;
System.out.println(c);
}
}
Addition Of Two Matrix By Using Thread.....!!
--------------------------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Threading;
namespace threadingmatrix
{
class Program
{
static int i, j;
static int[,] arr = new int[3, 3];
static int[,] arr2 = new int[3, 3];
static int[,] arr3 = new int[3, 3];
public static void insert()
{
Console.WriteLine("Enter First Elements in Array...");
for (i = 0; i < 3; i++)
{
for (j = 0; j < 3; j++)
{
Console.ForegroundColor = ConsoleColor.Yellow;
arr[i, j] = int.Parse(Console.ReadLine());
}
}
Console.WriteLine("Enter Second Elements in Array...");
for (i = 0; i < 3; i++)
{
for (j = 0; j < 3; j++)
{
Console.ForegroundColor = ConsoleColor.Cyan;
arr2[i, j] = int.Parse(Console.ReadLine());
}
}
}
public static void display()
{
Console.WriteLine("First Elements in Matrix...");
for (i = 0; i < 3; i++)
{
for (j = 0; j < 3; j++)
{
Console.ForegroundColor = ConsoleColor.Red;
Console.Write(arr[i, j] + "\t");
Thread.Sleep(2000);
}
Console.WriteLine();
}
Console.WriteLine("Second Elements in Matrix...");
for (i = 0; i < 3; i++)
{
for (j = 0; j < 3; j++)
{
Console.ForegroundColor = ConsoleColor.Blue;
Console.Write(arr2[i, j] + "\t");
Thread.Sleep(2000);
}
Console.WriteLine();
}
Console.WriteLine("Addition Of Two Matrix....");
for (i = 0; i < 3; i++)
{
for (j = 0; j < 3; j++)
{
arr3[i, j] = arr[i, j] + arr2[i, j];
}
}
for (i = 0; i < 3; i++)
{
for (j = 0; j < 3; j++)
{
Console.ForegroundColor = ConsoleColor.Green;
Console.Write(arr3[i, j] + "\t");
Thread.Sleep(2000);
}
Console.WriteLine();
}
}
static void Main(string[] args)
{
Program.insert();
Thread t = new Thread(new ThreadStart(display));
t.Start();
Console.ReadLine();
}
}
}
Example Of User-Defined Exception In C #
----------------------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace negativenumberexception
{
class Program
{
static void Main(string[] args)
{
number n = new number();
try
{
n.show();
}
catch (negativenumberexception ee)
{
Console.WriteLine(ee);
}
Console.ReadLine();
}
}
class negativenumberexception :Exception
{
public negativenumberexception(string message)
: base(message)
{
}
}
class number
{
int a;
public void show()
{
Console.WriteLine("Enter First Number");
a = int.Parse(Console.ReadLine());
if (a < 0)
{
throw (new negativenumberexception("Negative Number"));
}
else
{
Console.WriteLine("Number Is:\t"+a);
}
}
}
}
A program by using arraylist to sort and reverse......in c-sharp
------------------------------------------------------------------------
using System;
using System.Collections;
class Program
{
public static void Main(string [] args)
{
// Create an ArrayList
ArrayList list = new ArrayList();
list.Add("Sunday");
list.Add("Monday");
list.Add("Tuesday");
list.Add("Saturday");
// Sort the ArrayList.
list.Sort();
// Display the ArrayList elements.
foreach (string value in list)
{
Console.WriteLine(value);
}
// Reverse the ArrayList.
list.Reverse();
// Display the ArrayList elements again.
foreach (string value in list)
{
Console.WriteLine(value);
}
Console.ReadLine();
}
}
For More :- www.onlineprogrammingsolutions.com