<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; AHK: If var and var - Возможно ли что-то такое?]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=5511&amp;type=atom" />
	<updated>2011-02-13T18:04:51Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=5511</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45122#p45122" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>teadrinker пишет:</cite><blockquote><p>Почему не работает? Всё работает! <em>Py := 250</em>, <em>A := 252</em>, значит <em>Py &lt; A</em>, а в условии — <em>Py &gt; A</em>, и сообщение не появляется.</p></blockquote></div><p>Да, методом проб и ошибок тоже увидел это )) Спасибо&nbsp; огромное за помощь)</p>]]></content>
			<author>
				<name><![CDATA[b.e.f.]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25704</uri>
			</author>
			<updated>2011-02-13T18:04:51Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45122#p45122</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45121#p45121" />
			<content type="html"><![CDATA[<p>Почему не работает? Всё работает! <em>Py := 250</em>, <em>A := 252</em>, значит <em>Py &lt; A</em>, а в условии — <em>Py &gt; A</em>, и сообщение не появляется.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2011-02-13T18:03:07Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45121#p45121</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45120#p45120" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>teadrinker пишет:</cite><blockquote><p>А как оно должно работать? Переменные <em>YI1</em> и <em>YI2</em> не определены. Вместо этого значения присвоены <em>IY1</em> и <em>IY2</em> (первые два символа перепутаны местами). Вывод: переменные нужно называть более внятно, желательно осмысленно. И не ставить рядом символы &quot;I&quot;, &quot;l&quot;, &quot;1&quot;.</p></blockquote></div><p>Прошу строго не судить, я только учусь) <br /></p><div class="codebox"><pre><code>Px := 850, Py := 250
A := 252, B := 256
if (Px &gt; 817 and Px &lt; 911 and Py &gt; A  and Py &lt; B)
   MsgBox, Все условия выполнены!</code></pre></div><p>Если я правильно понял, теперь я присваиваю значения А и В, следовательно они определены? Но все равно не работает((</p>]]></content>
			<author>
				<name><![CDATA[b.e.f.]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25704</uri>
			</author>
			<updated>2011-02-13T17:54:00Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45120#p45120</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45117#p45117" />
			<content type="html"><![CDATA[<p>А как оно должно работать? Переменные <em>YI1</em> и <em>YI2</em> не определены. Вместо этого значения присвоены <em>IY1</em> и <em>IY2</em> (первые два символа перепутаны местами). Вывод: переменные нужно называть более внятно, желательно осмысленно. И не ставить рядом символы &quot;I&quot;, &quot;l&quot;, &quot;1&quot;.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2011-02-13T17:40:20Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45117#p45117</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45116#p45116" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>Px := 850, Py := 250
IY1 := 252, IY2 := 256
if (Px &gt; 817 and Px &lt; 911 and Py &gt; YI1  and Py &lt; YI2)
   MsgBox, Все условия выполнены!</code></pre></div><p>А почему так не работает, не подскажите?)</p>]]></content>
			<author>
				<name><![CDATA[b.e.f.]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25704</uri>
			</author>
			<updated>2011-02-13T17:30:53Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45116#p45116</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45115#p45115" />
			<content type="html"><![CDATA[<p>Да, действительно, без скобок только одиночное сравнение работает.</p>]]></content>
			<author>
				<name><![CDATA[YMP]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=81</uri>
			</author>
			<updated>2011-02-13T15:15:47Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45115#p45115</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45114#p45114" />
			<content type="html"><![CDATA[<p>Совсем без скобок нельзя:<br /></p><div class="codebox"><pre><code>Px := 850, Py := 10000
if Px &gt; 817 and Px &lt; 911 and Py &gt; 252 and Py &lt; 256
   MsgBox, Все условия выполнены!</code></pre></div><p>Можно так:<br /></p><div class="codebox"><pre><code>Px := 850, Py := 255
if (Px &gt; 817 and Px &lt; 911 and Py &gt; 252 and Py &lt; 256)
   MsgBox, Все условия выполнены!</code></pre></div>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2011-02-13T14:53:37Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45114#p45114</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45112#p45112" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>teadrinker пишет:</cite><blockquote><p>Точнее будет так:<br /></p><div class="codebox"><pre><code>Px := 850, Py := 255
if (Px &gt; 817 and Px &lt; 911) and (Py &gt; 252 and Py &lt; 256)
   MsgBox, Все условия выполнены!</code></pre></div></blockquote></div><p>Спасибо, все работает <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[b.e.f.]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25704</uri>
			</author>
			<updated>2011-02-13T14:47:23Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45112#p45112</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45111#p45111" />
			<content type="html"><![CDATA[<p><strong>teadrinker</strong><br />А зачем скобки-то? Они ничего не дают.</p>]]></content>
			<author>
				<name><![CDATA[YMP]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=81</uri>
			</author>
			<updated>2011-02-13T14:47:14Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45111#p45111</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45110#p45110" />
			<content type="html"><![CDATA[<p>Точнее будет так:<br /></p><div class="codebox"><pre><code>Px := 850, Py := 255
if (Px &gt; 817 and Px &lt; 911) and (Py &gt; 252 and Py &lt; 256)
   MsgBox, Все условия выполнены!</code></pre></div>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2011-02-13T14:36:18Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45110#p45110</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45109#p45109" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>ypppu пишет:</cite><blockquote><div class="codebox"><pre><code>var1:=10
var2:=20
If (var1&gt;1) and (var2&lt;40)
msgbox, Оба условия выполнены</code></pre></div></blockquote></div><p>Спасибо, пытаюсь переварить и адаптировать для себя <img src="//forum.script-coding.com/img/smilies/roll.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[b.e.f.]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25704</uri>
			</author>
			<updated>2011-02-13T14:31:31Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45109#p45109</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45108#p45108" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>var1:=10
var2:=20
If (var1&gt;1) and (var2&lt;40)
msgbox, Оба условия выполнены</code></pre></div>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2011-02-13T14:26:52Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45108#p45108</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: If var and var - Возможно ли что-то такое?]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=45107#p45107" />
			<content type="html"><![CDATA[<p>Всем доброе время суток. Заранее прошу прощение, если вдруг подобная тема создавалась, но я найти подобного не смог <img src="//forum.script-coding.com/img/smilies/sad.png" width="15" height="15" />.<br />Хочу реализовать нечто такое:<br /></p><div class="codebox"><pre><code>PixelSearch, Px, Py, 805, 183, 943, 305, 0xD4D4D4, 3, Fast ; ищем нужный цвет
      if ErrorLevel
          MsgBox, That color was not found in the specified region.
      if  (Px between 817 and 911) and (Py between 252 and 256) ; если (координата Х нужного цвета пикселя находится между 817 и 911) и 
                                                                       (координата У этого же пикселя находится между 252 и 256)
     goto, metka

metka:</code></pre></div><p>Очень важно чтобы исполнялось двойное условие. Перепробовал всячески: ставил скобки везде, не ставил итд. Буду очень благодарен, если кто-то поможет.</p>]]></content>
			<author>
				<name><![CDATA[b.e.f.]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25704</uri>
			</author>
			<updated>2011-02-13T13:51:28Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=45107#p45107</id>
		</entry>
</feed>
