<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; AHK: Как задать SetTimer переменной]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=10778&amp;type=atom" />
	<updated>2015-07-12T22:16:45Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=10778</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как задать SetTimer переменной]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=95321#p95321" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>#Persistent</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Malcev]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=26930</uri>
			</author>
			<updated>2015-07-12T22:16:45Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=95321#p95321</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: Как задать SetTimer переменной]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=95319#p95319" />
			<content type="html"><![CDATA[<p>Как использовать переменную в SetTimer?<br /></p><div class="codebox"><pre><code>x := 2000

SetTimer, Test, %x%
Return

Test:
MsgBox, Успешно
Return</code></pre></div><p>Нашел на англоязычном форуме следующий вид, но тоже не работает:<br /></p><div class="codebox"><pre><code>x = 2000

y := 0

SetTimer, Test, %x%
Return

Test:
MsgBox, Успешно
y++
if y != 2
SetTimer, Test, %x%
Else
SetTimer, Test, Off
Return</code></pre></div><p>Добавлено:<br />Забавно, но так работает:<br /></p><div class="codebox"><pre><code>x = 2000

y := 0

Loop
{
SetTimer, Test, %x%
sleep, 10000
}
Return

Test:
MsgBox, Успешно
SetTimer, Test, Off
Return</code></pre></div><p>И так тоже:<br /></p><div class="codebox"><pre><code>x := 2000

F1::
SetTimer, Test, %x%
Return

Test:
MsgBox, Успешно
SetTimer, Test, Off
Return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Странникх]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=30605</uri>
			</author>
			<updated>2015-07-12T21:41:35Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=95319#p95319</id>
		</entry>
</feed>
