<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; AHK: Завершение процесса другого скрипта]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=12430&amp;type=atom" />
	<updated>2018-01-19T17:26:26Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=12430</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Завершение процесса другого скрипта]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=123204#p123204" />
			<content type="html"><![CDATA[<p><strong>teadrinker</strong><br />Благодарю))))))))))))))</p>]]></content>
			<author>
				<name><![CDATA[Adam_Rockwell]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=39014</uri>
			</author>
			<updated>2018-01-19T17:26:26Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=123204#p123204</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Завершение процесса другого скрипта]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=112259#p112259" />
			<content type="html"><![CDATA[<p><strong>teadrinker</strong><br />Спасибо, долго искал так и не нашел.<br />Ваш способ работает как нужно. <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[slavafedora]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=34221</uri>
			</author>
			<updated>2017-02-12T12:51:36Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=112259#p112259</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Завершение процесса другого скрипта]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=112257#p112257" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>ScriptFileName := &quot;ScriptToBeClosed.ahk&quot;   ; написать название файла целевого скрипта
SetTitleMatchMode, 2
DetectHiddenWindows, On
WinClose, % ScriptFileName &quot; ahk_class AutoHotkey&quot;</code></pre></div>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2017-02-12T12:33:44Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=112257#p112257</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Завершение процесса другого скрипта]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=112255#p112255" />
			<content type="html"><![CDATA[<p><span style="color: green">Заголовок приведён в соответствие запросу.</span></p>]]></content>
			<author>
				<name><![CDATA[Flasher]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27593</uri>
			</author>
			<updated>2017-02-12T12:12:32Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=112255#p112255</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Завершение процесса другого скрипта]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=112253#p112253" />
			<content type="html"><![CDATA[<p>Закрывает все скрипты, кроме запускаемого:<br /></p><div class="codebox"><pre><code>vk31:: ; 1

#Persistent

PID:=DllCall(&quot;GetCurrentProcessId&quot;)
query:=&quot;SELECT Handle FROM Win32_Process WHERE Caption=&#039;AutoHotkey.exe&#039;&quot;

If (oWMI:=ComObjGet(&quot;winmgmts:&quot;).ExecQuery(query)).Count&gt;1
   For colItem In oWMI
      If colItem.Handle!=PID
         colItem.Terminate()

PID:=query:=oWMI:=&quot;&quot;

return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[svoboden]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=34280</uri>
			</author>
			<updated>2017-02-12T12:04:25Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=112253#p112253</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Завершение процесса другого скрипта]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=112252#p112252" />
			<content type="html"><![CDATA[<p>Воспользуйтесь поиском по&nbsp; словам &quot;параметры командной строки&quot; - найдёте в Коллекции примеры от <strong>Androgen</strong> по считыванию параметров другого процесса.</p><p>Или можно проще сделать. В каждом скрипте присвоить окну уникальный заголовок. Зная этот заголовок, выйти на PID процесса (командой <em>WinGet</em>).</p>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2017-02-12T10:40:37Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=112252#p112252</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: Завершение процесса другого скрипта]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=112251#p112251" />
			<content type="html"><![CDATA[<p>Добрый день форумчане. Появился у меня тут такой вопрос, возможно ли с помощью одного скрипта закрыть другой активный скрипт? Не данный, а другой. Если запущено два.<br />Знаю есть такая функция работы с процессом как:<br /></p><div class="codebox"><pre><code>Numpad0::Process, close, process.exe</code></pre></div><p>Эта функция не подходит к ahk, т.к там нужно указывать процесс приложения а его процесс один для всех скриптов запущенных.<br />Вопрос в другом как можно это реализовать, может кто-то сталкивался?</p>]]></content>
			<author>
				<name><![CDATA[slavafedora]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=34221</uri>
			</author>
			<updated>2017-02-12T09:41:43Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=112251#p112251</id>
		</entry>
</feed>
