Monday, 4 February 2019

Running an Executable File from Web

Here is the code for running Executable File from Web:

// Create a Process Object here. 
            System.Diagnostics.Process process1 = new System.Diagnostics.Process();
            //Working Directory Of .exe File. 
            process1.StartInfo.WorkingDirectory = Request.MapPath("~/");
            //exe File Name. 
            process1.StartInfo.FileName = Request.MapPath("GenerateBillConsole/GenerateBill.exe");
            //Argement Which you have tp pass. 
            process1.StartInfo.Arguments = " ";
            process1.StartInfo.LoadUserProfile = true;
            //Process Start on exe.
            process1.Start();
            process1.WaitForExit();
            process1.Close();

Happy Coding !!!

SQL Audits

1. sys.server_audits What it is: Lists all server-level audit objects . An audit is the top-level object that defines: Where to wri...