<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; VBScript: Работа с проводником Windows (поиск файлов)]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=9297&amp;type=atom" />
	<updated>2014-02-25T10:39:01Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=9297</id>
		<entry>
			<title type="html"><![CDATA[Re: VBScript: Работа с проводником Windows (поиск файлов)]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=80367#p80367" />
			<content type="html"><![CDATA[<p>Спасибо большое! Это именно то, что нужно.</p>]]></content>
			<author>
				<name><![CDATA[E_v_g]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=31847</uri>
			</author>
			<updated>2014-02-25T10:39:01Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=80367#p80367</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBScript: Работа с проводником Windows (поиск файлов)]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=80358#p80358" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>E_v_g пишет:</cite><blockquote><p>(SendKeys не хочет работать)</p></blockquote></div><p>По идее, должен.<br /></p><div class="quotebox"><cite>E_v_g пишет:</cite><blockquote><p>1. Как заполнить поля окна поиска: имя файла, слово или фраза в файле?</p></blockquote></div><p>Возможно, с помощью <em>AutoItX3.Control</em><br /></p><div class="quotebox"><cite>E_v_g пишет:</cite><blockquote><p>2. Самое главное - как получить список найденных файлов?</p></blockquote></div><p>JScript (поленился переводить на VBS):<br /></p><div class="codebox"><pre><code>SearchResultsFolderPath = &quot;::{E17D4FC0-5564-11D1-83F2-00A0C90DC849}&quot;
Shell = new ActiveXObject(&quot;Shell.Application&quot;);
ShellWindows = Shell.Windows();
for (i = ShellWindows.Count; --i &gt;= 0;) try {
    Folder = ShellWindows.Item(i).Document.Folder;
    if (Folder.Self.Path.toUpperCase() == SearchResultsFolderPath) break;
} catch (Err) {}
if (i &lt; 0) {
    WScript.Echo(&quot;Окно не найдено&quot;);
    WScript.Quit(1);
}
FolderItems = Folder.Items();
Count = FolderItems.Count;
for (i=0; i &lt; Count; i++) {
    Item = FolderItems.Item(i);
    WScript.Echo(Item.Path);
}
</code></pre></div>]]></content>
			<author>
				<name><![CDATA[wisgest]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=3850</uri>
			</author>
			<updated>2014-02-24T16:18:44Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=80358#p80358</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[VBScript: Работа с проводником Windows (поиск файлов)]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=80354#p80354" />
			<content type="html"><![CDATA[<p>Запускаю поиск (Пуск - Найти - Файлы и папки):<br /></p><div class="codebox"><pre><code>Set objShellApp = CreateObject(&quot;Shell.Application&quot;)
objShellApp.ShellExecute &quot;&quot;, &quot;&quot;, &quot;d:\&quot;, &quot;find&quot;, 1</code></pre></div><p>1. Как заполнить поля окна поиска: имя файла, слово или фраза в файле? (SendKeys не хочет работать)<br />2. Самое главное - как получить список найденных файлов?</p>]]></content>
			<author>
				<name><![CDATA[E_v_g]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=31847</uri>
			</author>
			<updated>2014-02-24T13:51:30Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=80354#p80354</id>
		</entry>
</feed>
