<?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=12630&amp;type=atom" />
	<updated>2017-04-21T15:24:01Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=12630</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Проверка процесса на принадлежность к службам]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115238#p115238" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>Flasher пишет:</cite><blockquote><p>Заголовок уточнён.</p></blockquote></div><p> Спасибо, а то я долго искал верное название.</p><p>Второй&nbsp; код чем принципиально отличается от второго, до комментария <strong>;Либо:</strong>? </p><p>P.S. Это для бестолковых... <img src="//forum.script-coding.com/img/smilies/wink.png" width="15" height="15" /> Вижу отличия, конечно, но желательно уточнить, если не сложно.</p><p><strong>UPD</strong><br />Всё, разобрался - вопрос закрыт.</p>]]></content>
			<author>
				<name><![CDATA[Indomito]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27285</uri>
			</author>
			<updated>2017-04-21T15:24:01Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115238#p115238</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Проверка процесса на принадлежность к службам]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115218#p115218" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>Path = C:\Windows\system32\svchost.exe

MsgBox % ComObjGet(&quot;winmgmts:&quot;).ExecQuery(&quot;SELECT * FROM Win32_Service WHERE PathName LIKE &#039;%&quot; . StrReplace(Path, &quot;\&quot;, &quot;\\&quot;) . &quot;%&#039;&quot;).Count ? &quot;Служба&quot; : &quot;Не служба&quot;</code></pre></div><div class="codebox"><pre><code>PID = 992

MsgBox % ComObjGet(&quot;winmgmts:&quot;).ExecQuery(&quot;SELECT * FROM Win32_Service WHERE ProcessId=&quot; . PID).Count ? &quot;Служба&quot; : &quot;Не служба&quot;

; Либо:
RunWait, %ComSpec% /c for /f `%# in (&#039;tasklist /fi &quot;SessionName eq Services&quot; /fi &quot;pid eq %PID%&quot;^|find /i /c &quot;.exe&quot;&#039;) do exit /b `%#,, Hide UseErrorLevel
MsgBox, % ErrorLevel ? &quot;Служба&quot; : &quot;Не служба&quot;</code></pre></div><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-04-21T07:39:54Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115218#p115218</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: Проверка процесса на принадлежность к службам]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=115217#p115217" />
			<content type="html"><![CDATA[<p>Приветствую. </p><p>Понадобилось мне идентифицировать/проверить процесс(ы) на принадлежность их к сервисам, а вот как, я лично не знаю.</p><p>Подскажите.</p>]]></content>
			<author>
				<name><![CDATA[Indomito]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27285</uri>
			</author>
			<updated>2017-04-21T04:29:49Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=115217#p115217</id>
		</entry>
</feed>
