AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Programmierung allgemein Win32/Win64 API (native code) Delphi TerminateProcess not working correctly....
Thema durchsuchen
Ansicht
Themen-Optionen

TerminateProcess not working correctly....

Ein Thema von FaNIX · begonnen am 22. Okt 2007 · letzter Beitrag vom 22. Okt 2007
 
FaNIX

Registriert seit: 8. Okt 2007
36 Beiträge
 
#8

Re: TerminateProcess not working correctly....

  Alt 22. Okt 2007, 09:24
Zitat von sirius:
Just use MSDN-Library durchsuchenwaitforsingleobject with a time out intervall of 0 milliseconds
Ahhh genius!!! It work's perfectly... thanks mate!

Delphi-Quellcode:
    try
        //Create the Desktop
        Desktop.CreateDesktop(VIRTUAL_DESKTOP);

        FillChar(sinfo, SizeOf(sinfo), 0);
        sinfo.cb := SizeOf(sinfo);
        sinfo.lpDesktop := PChar(VIRTUAL_DESKTOP);

        sFileName := ExtractFilePath(Application.EXEName) + 'c_IPU_Sender_Appl.exe';
        sFileName := sFileName +' '+ VIRTUAL_DESKTOP +' '+ Fs_LANUser;

        //Run the Message Sending Application on the new Desktop
        CreateProcess(nil,PChar(sFileName), nil, nil, False, 0, nil, nil, sinfo, pinfo);
        Fi_ProcessID := pinfo.dwProcessId;

        //Which to the new Desktop
        Desktop.SwitchToDesktop(VIRTUAL_DESKTOP);
        WaitForSingleObject(pinfo.hProcess, INFINITE);
    except
        on E: Exception do
            HandleError(E.Message);
    end;
  Mit Zitat antworten Zitat
 


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 09:22 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-2025 by Thomas Breitkreuz