Processing Ajax...

Title

Message

Confirm

Confirm

Confirm

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure?

Kill current process

Description
This script will kill the process of the window that the script was run on.
Language
C#.net
Minimum Version
Created By
Renan Gonçalves Micheletti
Contributors
-
Date Created
Feb 14, 2022
Date Last Modified
Feb 14, 2022

Scripted Function (Macro) Code

using System;
using System.Drawing;
using System.Diagnostics;

public static class DisplayFusionFunction
{
	public static void Run(IntPtr windowHandle)
	{
			uint processID = BFS.Application.GetAppIDByWindow(windowHandle);
            Process process = new Process();
            process.StartInfo.FileName = "taskkill.exe";
            process.StartInfo.Arguments = "/PID " + processID + " /f";
            process.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;
            process.StartInfo.CreateNoWindow = true;
            process.Start();
	}
}