Sorry if the question wasn't clear, it'd be too much to type if it were.

I found some code a few days ago that reads the executable path of every process but returns an error when trying to get certain processes. I didn't make all of this code :
Code:
        Dim example as integer
        Dim file2 As String
        For Each p As Process In Process.GetProcesses
            Try
                file2 = p.Modules(0).FileName
...