AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Sprachen und Entwicklungsumgebungen Object-Pascal / Delphi-Language Delphi How know what process is using a determinated file through NtQueryInformationFile?
Thema durchsuchen
Ansicht
Themen-Optionen

How know what process is using a determinated file through NtQueryInformationFile?

Ein Thema von flashcoder · begonnen am 6. Apr 2018 · letzter Beitrag vom 9. Apr 2018
Antwort Antwort
flashcoder

Registriert seit: 10. Nov 2013
83 Beiträge
 
#1

AW: How know what process is using a determinated file through NtQueryInformationFile

  Alt 9. Apr 2018, 12:55
Hi there, i have to admit that i dont understand everthing yet, especially the "NtQueryInformationFile" call.
If you want to iterate files and folders i could give you a way shorter method.
I want that when next file is verified and be the same(s) previous process(es) using this file, not show yours exe name.

My last attempt:

Delphi-Quellcode:
var
 currPid, oldPid : LongWord; // Global

...

for I := 0 to High(P.ProcessIdList) do
  begin
    if P.ProcessIdList[I] = pe.th32ProcessID then
    begin
      oldPid := currPid;
      currPid := pe.th32ProcessID;
      if currPid <> oldPid then
        Form1.mmo1.Lines.Add(pe.szExeFile);
      Break;
    end;
  end;
  Mit Zitat antworten Zitat
Antwort Antwort


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 15:11 Uhr.
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz