Skip to content

Instantly share code, notes, and snippets.

@Fhernd
Created October 1, 2014 12:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Fhernd/6f709ff5ffc4005b2221 to your computer and use it in GitHub Desktop.
Save Fhernd/6f709ff5ffc4005b2221 to your computer and use it in GitHub Desktop.
Demostración del uso del método `Kill` de `Process`.
using System;
using System.Diagnostics;
using System.Threading;
namespace Receta.CSharp.R0416
{
public sealed class UsoKill
{
public static void Main()
{
// Creación de proceso de Bloc de notas:
Process procesoBlocNotas = Process.Start ("notepad.exe");
// Espera de 3 segundos:
Thread.Sleep (3000);
// Terminación abrupta del Bloc de notas:
procesoBlocNotas.Kill ();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment