<?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=7992&amp;type=atom" />
	<updated>2013-01-21T01:44:55Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=7992</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Рандомный текст.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=68734#p68734" />
			<content type="html"><![CDATA[<p>Немножко трудно было, но по первым тестам вроде работает. Спасибо еще раз.<br /></p><div class="codebox"><pre><code>
Numpad0::
   Random, Var, 1, 4
   SendInput, % TextArray[Var] . &quot;{Enter}&quot;

TextArray := [&quot;Вариант номер AAA1&quot;
            , &quot;Вариант номер AAA2&quot;
            , &quot;Вариант номер AAA3&quot;
            , &quot;Вариант номер AAA4&quot;]

   Exit


Numpad1::
   Random, Var, 1, 4
   SendInput, % TextArray2[Var] . &quot;{Enter}&quot;

TextArray2 := [&quot;Вариант номер BBB1&quot;
            , &quot;Вариант номер BBB2&quot;
            , &quot;Вариант номер BBB3&quot;
            , &quot;Вариант номер BBB4&quot;]

   Exit</code></pre></div>]]></content>
			<author>
				<name><![CDATA[islamsaab]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27172</uri>
			</author>
			<updated>2013-01-21T01:44:55Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=68734#p68734</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Рандомный текст.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=68733#p68733" />
			<content type="html"><![CDATA[<p>Определение обоих массивов должно находиться в <a href="http://script-coding.com/AutoHotkey/Scripts.html#chapter_1">секции автовыполнения</a>.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2013-01-21T01:30:50Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=68733#p68733</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Рандомный текст.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=68732#p68732" />
			<content type="html"><![CDATA[<p>Спасибо большое. Работает изумительно.<br />Теперь у меня следующая проблема возникла:</p><div class="codebox"><pre><code>TextArray := [&quot;Вариант номер AAA1&quot;
            , &quot;Вариант номер AAA2&quot;
            , &quot;Вариант номер AAA3&quot;
            , &quot;Вариант номер AAA4&quot;]

Numpad0::
   Random, Var, 1, 4
   SendInput, % TextArray[Var] . &quot;{Enter}&quot;
   return

TextArray := [&quot;Вариант номер BBB1&quot;
            , &quot;Вариант номер BBB2&quot;
            , &quot;Вариант номер BBB3&quot;
            , &quot;Вариант номер BBB4&quot;]

Numpad1::
   Random, Var, 1, 4
   SendInput, % TextArray[Var] . &quot;{Enter}&quot;
   return</code></pre></div><p>Мне нужно, чтобы в одном скрипте была возможность на разные клавиши повесить рандомные действия. Но почему то и Numpad1 и Numpad0 ссылаются на &quot;Вариант номер ВВВ№&quot;.&nbsp; Я подумал, что нужно после TextArray поставить простой обозначитель:</p><div class="codebox"><pre><code>TextArray := [&quot;Вариант номер AAA1&quot;
            , &quot;Вариант номер AAA2&quot;
            , &quot;Вариант номер AAA3&quot;
            , &quot;Вариант номер AAA4&quot;]

Numpad0::
   Random, Var, 1, 4
   SendInput, % TextArray[Var] . &quot;{Enter}&quot;
   return

TextArrayBBB := [&quot;Вариант номер BBB1&quot;
            , &quot;Вариант номер BBB2&quot;
            , &quot;Вариант номер BBB3&quot;
            , &quot;Вариант номер BBB4&quot;]

Numpad1::
   Random, Var, 1, 4
   SendInput, % TextArrayBBB[Var] . &quot;{Enter}&quot;
   return</code></pre></div><p>чтобы Numpad1 знал на какой TextArray ссылаться, но не сработало. Просто пустая строка и Enter срабатывает. Клавишь у меня будет много с рандомным выводом текста и делать на каждую отдельный скрипт и запускать по отдельности не реально для меня.</p>]]></content>
			<author>
				<name><![CDATA[islamsaab]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27172</uri>
			</author>
			<updated>2013-01-21T00:49:23Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=68732#p68732</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Рандомный текст.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=68731#p68731" />
			<content type="html"><![CDATA[<p>Обнови AHK до актуальной версии.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2013-01-20T23:52:35Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=68731#p68731</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Рандомный текст.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=68730#p68730" />
			<content type="html"><![CDATA[<p>Хорошо. <br />Выдает ошибку illegal character... program will exit.</p>]]></content>
			<author>
				<name><![CDATA[islamsaab]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27172</uri>
			</author>
			<updated>2013-01-20T23:49:36Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=68730#p68730</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Рандомный текст.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=68729#p68729" />
			<content type="html"><![CDATA[<div class="codebox"><pre><code>TextArray := [&quot;Вариант номер 1&quot;
            , &quot;Вариант номер 2&quot;
            , &quot;Вариант номер 3&quot;
            , &quot;Вариант номер 4&quot;]

Numpad0::
   Random, Var, 1, 4
   SendInput, % TextArray[Var] . &quot;{Enter}&quot;
   return</code></pre></div><p><span style="color: #008800"><strong>islamsaab</strong>, обрати <a href="http://forum.script-coding.com/viewtopic.php?id=6148">внимание</a> на оформление кода.</span></p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2013-01-20T23:23:50Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=68729#p68729</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: Рандомный текст.]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=68728#p68728" />
			<content type="html"><![CDATA[<p>Здраствуйте, меня интересует как сделать на клавишу (рандомную) печать текста. Вот например</p><div class="codebox"><pre><code>Numpad0::Send, Вариант номер 1{enter}</code></pre></div><p>Это мне позволяет отправить сообщение Вариант номер 1, но как сделать, чтобы на одну кнопку вариантов было множество и главное рандомно. Если нельзя сделать рандомно, то можно ли сделать, чтобы на одну клавишу разный текст поочередно шел? Если хоть какой-то вариант возможен, то дайте пожалуйста что-нибудь рабочее, чтобы я смог по шаблону использовать скрипт. Спасибо.</p>]]></content>
			<author>
				<name><![CDATA[islamsaab]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27172</uri>
			</author>
			<updated>2013-01-20T22:29:18Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=68728#p68728</id>
		</entry>
</feed>
