Community Center | Not monitored
Tag not monitored by Microsoft.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Dear all,
I'm getting the below on error on this code:
Sub GetPidVersionTwo()
Dim objSWbemServices As Object
Dim colSWbemObjectSet As Object
Dim objSWbemObject As Object
Dim StrComputer As String
Dim RstProcess As ADODB.Recordset
Dim CommandLineToSearch As String
Dim StrExecQuery As String
StrComputer = "."
StrExecQuery = "SELECT ProcessID, Name, CommandLine FROM Win32_Process WHERE Name = 'MSACCESS.EXE' and CommandLine Like '%D:\Database\Sample.accdb%'"
I'm sure the issue is on the path D:\Database\Sample.accdb; any way to fix it?
Thanks