[VB.NET] Get Active Processes and Services

  • Hello Guest! Welcome to ConsoleCrunch, to help support our site check out the premium upgrades HERE! to get exclusive access to our hidden content.
  • Unable to load portions of the website...
    If you use an ad blocker addon, you should disable it because it interferes with several elements of the site and blocks more than just adverts.
  • Read Rules Before Posting Post Virus Scans with every program.

1UP

Member
Oct 9, 2014
24
10
63
This kinda works much like Task manager except in this example you can't end the process / service. I do plan on actually making a slimmed down version of task manager in the future so those who get infected with malware and lose rights to use it will still be able to find out what is running and possibly stop the virus from running.

Anywho, we'll start off with our imports:

Code:
Imports System.ServiceProcess

Now to get the active processes and put them into a listbox as well as the services

Code:
 Dim processList() As Process
  Dim ServiceCon() As ServiceController = ServiceController.GetServices()
  Dim saveFile As IO.StreamWriter
  Dim eachline As Integer
  Try
  processList = Process.GetProcesses()
  For Each proc As Process In processList
  lst_process_list.Items.Add(proc.ProcessName)
  Next (proc)

  saveFile = New IO.StreamWriter(".\processes.txt")

  For i = 0 To lst_process_list.Items.Count - 1
  saveFile.WriteLine(lst_process_list.Items.Item(i))
  Next
  saveFile.Close()

  For Each serv As ServiceController In ServiceCon
  If serv.Status.ToString() = "Running" Then
  lst_service_list.Items.Add(serv.ServiceName)
  End If
  Next serv

  saveFile = New IO.StreamWriter(".\services.txt")
  For i = 0 To lst_service_list.Items.Count - 1
  saveFile.WriteLine(lst_service_list.Items.Item(i))
  Next
  saveFile.Close()

  Catch ex As Exception



  End Try


Not a whole lot to explain here other then it was never finished. There should be some sort of error message if for whatever reason it hits the catch. Also this will save a text tile with the current services and processes running.
 
General chit-chat
Help Users
  • @ QM|T_JinX:
    het bro nice work man
  • @ QM|T_JinX:
    with ?
  • @ EMRR:
    What do you mean? I can't understand "with ?"
  • @ QM|T_JinX:
    you ask can you help me and i said with what can i help you out
  • @ EMRR:
    Can you help me about share my generated CID's? Where can i share it on this website?
  • @ QM|T_JinX:
    you can put it in cid section or ps3 section in general
  • @ EMRR:
    Ok, thanks :)
  • @ QM|T_JinX:
    np bro
  • Chat Bot:
    EMRR has started a new thread called "Working Console ID" in Console ID's.
  • Chat Bot:
    EMRR has started a new thread called "Console ID 1" in Console ID's.
  • Chat Bot:
    wadu is our newest member. Welcome!
  • Chat Bot:
    EMRR has started a new thread called "Console ID 2" in Console ID's.
  • Chat Bot:
    QM|T_JinX has posted a new reply in the thread "Console ID 2".
  • @ lurch6661:
    gold hen out soon
  • Chat Bot:
    Christo has joined the room.
  • @ lurch6661:
    zap
  • @ lurch6661:
    trying to figure out how to run a rpf files
  • @ lurch6661:
    on gta5
  • @ lurch6661:
    i guess there is a way were you can upload real cars \
  • @ QM|T_JinX:
    rpf is a update like / update.rpf
  • @ lurch6661:
    also i cant find dmz
  • @ lurch6661:
    is that not warzone
  • Chat Bot:
    Nazzysam is our newest member. Welcome!
    Chat Bot: Nazzysam is our newest member. Welcome!