Prozesse |
EinführungMit den Prozess Befehlen werden Programme gestartet.Prozesse können Synchron oder Asynchron laufen. Wenn ein Programm synchron gestartet wird, hält Nano an bis es beendet ist. Ein asynchron gestartes Programm läuft parallel. Nano läuft weiter. Das folgende Beispiel startet das Windows Notepad: // process.na // launching a program #setreg_l L0, null; #setreg_l L1, one; #setreg_l L2, two; #setreg_l L3, process; #setreg_l L4, retcode; push_i 0, null; push_i 1, one; push_i 2, two; string prog[256]; move_s "C:/windows/system32/notepad.exe", prog; print_s "running notepad..."; print_n one; runpr prog, process; // wait until process ends waitpr process, retcode; print_s "return code: "; print_l retcode; print_n two; exit null; BefehleL = long Register, SV = string Variable runpr SV (program name), L (process number); starte Programm runsh SV (program name), L (return code); starte Shell waitpr L (process number), L (return code); warte auf Programmende FehlercodesDie Befehle geben einen Fehlercode in der Variablen "_process" zurück.Siehe die Include Datei "process.nah". AmigaDie Befehle sind im Amiga Port nicht implementiert.Der Grund dafür ist Einfach: Ich konnte keine ausführliche Informationen finden. Wenn du mehr weißt, dann schreib mir bitte. Prev: TCP/IP Sockets | Next: Stack |