<?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=11500&amp;type=atom" />
	<updated>2016-04-16T15:02:46Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=11500</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: вывод строки при совпадении со смежными]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=102634#p102634" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>var = 
(
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Иван&lt;/td&gt;
&lt;td&gt;60 лет&lt;/td&gt;
&lt;td&gt;Москва&lt;/td&gt;
&lt;/tr&gt;
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Александр&lt;/td&gt;
&lt;td&gt;30 лет&lt;/td&gt;
&lt;td&gt;Киев&lt;/td&gt;
&lt;/tr&gt;
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Анна&lt;/td&gt;
&lt;td&gt;30 лет&lt;/td&gt;
&lt;td&gt;Москва&lt;/td&gt;
&lt;/tr&gt;
)

result := Object()
Pos := 1, match := &quot;&quot;
While Pos := Regexmatch(var, &quot;s)(?:^|\R)&lt;td&gt;&lt;span class=&quot;&quot;user-icon&quot;&quot;&gt;&lt;/span&gt;(\D*)&lt;/td&gt;(?:[^\r\n]*\R){2}&lt;td&gt;Москва&lt;/td&gt;(?:$|\R)&quot;, match, Pos+StrLen(match))
   result[A_Index] := match1

loop % result.MaxIndex()
{
	Msgbox % result[A_Index]
}</code></pre></div>]]></content>
			<author>
				<name><![CDATA[mafckz]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=32877</uri>
			</author>
			<updated>2016-04-16T15:02:46Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=102634#p102634</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: вывод строки при совпадении со смежными]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=102626#p102626" />
			<content type="html"><![CDATA[<p>Cпасибо, выручили. Еще плохо разбираюсь в этой области, поэтому спрошу еще:<br />можно ли выводить каждого&nbsp; человека по данным результатам в отдельных, последовательно открывающихся окнах (нажал ОК - вывелось следующее имя)?</p>]]></content>
			<author>
				<name><![CDATA[darthmakr]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=33829</uri>
			</author>
			<updated>2016-04-16T10:39:03Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=102626#p102626</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: вывод строки при совпадении со смежными]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=102623#p102623" />
			<content type="html"><![CDATA[<p>По образцу кода от Malcev&#039;a (<a href="http://forum.script-coding.com/viewtopic.php?pid=102405#p102405">http://forum.script-coding.com/viewtopi … 05#p102405</a>) :<br /></p><div class="codebox"><pre><code>var = 
(
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Иван&lt;/td&gt;
&lt;td&gt;60 лет&lt;/td&gt;
&lt;td&gt;Москва&lt;/td&gt;
&lt;/tr&gt;
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Александр&lt;/td&gt;
&lt;td&gt;30 лет&lt;/td&gt;
&lt;td&gt;Киев&lt;/td&gt;
&lt;/tr&gt;
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Анна&lt;/td&gt;
&lt;td&gt;30 лет&lt;/td&gt;
&lt;td&gt;Москва&lt;/td&gt;
&lt;/tr&gt;
)
Pos := 1, match := &quot;&quot;
While Pos := Regexmatch(var, &quot;s)(?:^|\R)&lt;td&gt;&lt;span class=&quot;&quot;user-icon&quot;&quot;&gt;&lt;/span&gt;(\D*)&lt;/td&gt;(?:[^\r\n]*\R){2}&lt;td&gt;Москва&lt;/td&gt;(?:$|\R)&quot;, match, Pos+StrLen(match))
   result .= match1 &quot;`n&quot;
msgbox % result</code></pre></div>]]></content>
			<author>
				<name><![CDATA[mafckz]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=32877</uri>
			</author>
			<updated>2016-04-16T02:40:32Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=102623#p102623</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: вывод строки при совпадении со смежными]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=102622#p102622" />
			<content type="html"><![CDATA[<p>День добрый. Есть следующая необходимость: из данного кода необходимо выводить лишь тех, чье проживание соответствует городу Москва. Выводить нужно именно имена. Реализуемо ли это?</p><div class="codebox"><pre><code>
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Иван&lt;/td&gt;
&lt;td&gt;60 лет&lt;/td&gt;
&lt;td&gt;Москва&lt;/td&gt;
&lt;/tr&gt;
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Александр&lt;/td&gt;
&lt;td&gt;30 лет&lt;/td&gt;
&lt;td&gt;Киев&lt;/td&gt;
&lt;/tr&gt;
&lt;tr class=&quot;displayed&quot;&gt;
&lt;td&gt;&lt;span class=&quot;user-icon&quot;&gt;&lt;/span&gt;Анна&lt;/td&gt;
&lt;td&gt;30 лет&lt;/td&gt;
&lt;td&gt;Москва&lt;/td&gt;
&lt;/tr&gt;
</code></pre></div>]]></content>
			<author>
				<name><![CDATA[darthmakr]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=33829</uri>
			</author>
			<updated>2016-04-16T01:09:17Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=102622#p102622</id>
		</entry>
</feed>
