<?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=10762&amp;type=atom" />
	<updated>2015-07-08T15:21:57Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=10762</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Установка значения переменной, которое зависит от другой перемен.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=95113#p95113" />
			<content type="html"><![CDATA[<p>Спасибо всем за ответы. Я пример play для примера кинул, чтобы вы поняли о чем идет речь.</p>]]></content>
			<author>
				<name><![CDATA[tuma4ok]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=32022</uri>
			</author>
			<updated>2015-07-08T15:21:57Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=95113#p95113</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Установка значения переменной, которое зависит от другой перемен.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=95111#p95111" />
			<content type="html"><![CDATA[<p>Ещё, в некоторых случаях можно использовать массив, наглядно когда много вариантов.<br /></p><div class="codebox"><pre><code>lang := &quot;ru&quot;
trans := {&quot;ru&quot;:&quot;en&quot;,&quot;en&quot;:&quot;ru&quot;}[lang]
MsgBox % trans</code></pre></div>]]></content>
			<author>
				<name><![CDATA[serzh82saratov]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27879</uri>
			</author>
			<updated>2015-07-08T14:25:42Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=95111#p95111</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Установка значения переменной, которое зависит от другой перемен.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=95108#p95108" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>trans := lang = &quot;ru&quot; ? &quot;en&quot; : &quot;ru&quot;</code></pre></div><p>Вариант типа <em>play := !play</em> здесь не подойдёт.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2015-07-08T14:09:18Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=95108#p95108</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: Установка значения переменной, которое зависит от другой перемен.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=95099#p95099" />
			<content type="html"><![CDATA[<p>Здравствуйте дорогие друзья. Возник вопрос с которым я все никак не могу разобраться. И так, приступим к описанию проблемы.<br />У меня есть переменная <strong>lang</strong>. Данная переменная может быть равна любому значению.<br />Так же у меня есть 2 переменная <strong>trans</strong>. Она должна зависеть от переменной <strong>lang</strong> следующим образом:<br />Если переменная <strong>lang</strong> != &quot;ru&quot; - то <strong>trans</strong> := &quot;ru&quot;<br />Если переменная <strong>lang = &quot;ru&quot;</strong> - то <strong>trans</strong> := &quot;en&quot;</p><p>Да, я мог бы сделать методами <strong>if</strong> и <strong>else</strong>, но мне нужно что-то в виде такого формата.<br /></p><div class="codebox"><pre><code>Status := (play := !play) ? &quot;Включен&quot; : &quot;Выключен&quot;</code></pre></div><p>Это код из старой темы. Так же, кому не сложно, попрошу вас объяснить как работать с такими переменными или как их назвать я не знаю. В общем, жду ваших ответов.<br />Заранее спасибо!</p>]]></content>
			<author>
				<name><![CDATA[tuma4ok]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=32022</uri>
			</author>
			<updated>2015-07-08T13:25:29Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=95099#p95099</id>
		</entry>
</feed>
