1.

How Do You Create Thread In .net?

Answer»
  1. Import SYSTEM.Threading
  2. Create a NEW THREAD using new Thread() and assign the ADDRESS of the method
  3. Use Thread.Start method to start the execution

using System;

using System.Threading;

public class TEST
{
static void Main()
{
ThreadStart job = new ThreadStart(ThreadJob);
Thread thread = new Thread(job);
thread.Start();

for (int i=0; i

using System;

using System.Threading;

public class Test
{
static void Main()
{
ThreadStart job = new ThreadStart(ThreadJob);
Thread thread = new Thread(job);
thread.Start();

for (int i=0; i



Discussion

No Comment Found