<?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=7205&amp;type=atom" />
	<updated>2012-07-04T01:56:18Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=7205</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61359#p61359" />
			<content type="html"><![CDATA[<p><strong>tiim</strong> посмотри <em>&quot;в сторону&quot;</em> <strong>AutoIt</strong> он наиболее, как мне кажется, тебе подойдёт, т.к. он немного схож с AHK, а его методы более стандартизированы - я про декларирование переменных например. <a href="http://ru.wikipedia.org/wiki/AutoIt">AutoIt — Википедия</a></p>]]></content>
			<author>
				<name><![CDATA[Indomito]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27285</uri>
			</author>
			<updated>2012-07-04T01:56:18Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61359#p61359</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61358#p61358" />
			<content type="html"><![CDATA[<p><strong>Indomito</strong>, обязательно попробую PascalABC.NET, VBS, AutoIt (правда когда буду чуток свободнее) . Я просто думал, что AHK самый простой язык.....</p>]]></content>
			<author>
				<name><![CDATA[tiim]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27991</uri>
			</author>
			<updated>2012-07-03T22:51:21Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61358#p61358</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61345#p61345" />
			<content type="html"><![CDATA[<p><strong>-off</strong><br /><a href="http://forum.script-coding.com/profile.php?id=27991">tiim</a> просто название скриптового языка <strong>AutoHotkey</strong> говорит само за себя... ну я бы не стал учится программированию на нём, есть более простые решения твоей цели.<br />Согласен, что <strong>Microsoft VS</strong> это монстр (мягко сказано), но есть например PascalABC.NET, VBS, AutoIt (если нравятся скриптовые языки)... список большой, простых и полнофункциональных (ну почти) языков.<br />IMHO</p>]]></content>
			<author>
				<name><![CDATA[Indomito]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27285</uri>
			</author>
			<updated>2012-07-03T07:44:01Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61345#p61345</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61344#p61344" />
			<content type="html"><![CDATA[<p><strong>Indomito</strong>, я просто пытаюсь разобраться в каком-то простом языке программирования, чтобы иногда по мере необходимости писать легкие программки для себя.<br />Правда в последнее время напряженка со свободным временем...</p>]]></content>
			<author>
				<name><![CDATA[tiim]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27991</uri>
			</author>
			<updated>2012-07-03T07:20:58Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61344#p61344</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61342#p61342" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>tiim пишет:</cite><blockquote><p>Этот скрипт я пытаюсь сделать для того чтобы понять как можно программировать в AHK...</p></blockquote></div><p>можно уточнить?</p><p><strong>К</strong>ак писать скрипты АНК?<br />&nbsp; <span class="bbu">или</span><br /><strong>К</strong>ак в AHK использовать GUI?</p><p>Если ты хорошо разобрался в AHK, то можно переходить к граф. интерфейсу пользователя, а если пытаешься перепрыгнуть...<br />В AHK GUI реализован не на 100% к желаемому, проще использовать например Microsoft VS 2010 Pro., меньше будет головной боли - IMHO.</p><p>P.S. Для каждого языка/инструмента своя цель - весьма оправданная.</p>]]></content>
			<author>
				<name><![CDATA[Indomito]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27285</uri>
			</author>
			<updated>2012-07-03T04:13:04Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61342#p61342</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61340#p61340" />
			<content type="html"><![CDATA[<p>Не совсем понял задачу, но вот пример смены списка ComboBox в зависимости от выбранного в DropDownList:<br /></p><div class="codebox"><pre><code>Gui, Add, DDL, vDDL gDDL, 1||2|3
Gui, Add, ComboBox, vComboBox, A||B|C
Gui, Show
return

DDL:
   Gui, Submit, NoHide

   if DDL = 1
      NewCombo = A||B|C
   else if DDL = 2
      NewCombo = D||E|F
   else if DDL = 3
      NewCombo = G||H|I
   
   GuiControl,, ComboBox, % &quot;|&quot; NewCombo
   return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2012-07-02T19:57:18Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61340#p61340</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61300#p61300" />
			<content type="html"><![CDATA[<p>Этот скрипт я пытаюсь сделать для того чтобы понять как можно программировать в AHK. Скрипт из себя представляет таблицу. Верхние выпадающие списки предназначены для выбора варианта решения. <br />у меня почему-то в списке Combobox значение не изменяется после того как его выберешь. А в остальном вроде разобрался....</p>]]></content>
			<author>
				<name><![CDATA[tiim]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27991</uri>
			</author>
			<updated>2012-06-30T14:40:24Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61300#p61300</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61252#p61252" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>tiim пишет:</cite><blockquote><p>Методом проб и ошибок накатал кое-что:):</p></blockquote></div><p>Напиши, как пользоваться данным скриптом, что куда записывать, и что и где должно появляться.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2012-06-28T12:25:32Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61252#p61252</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=61251#p61251" />
			<content type="html"><![CDATA[<p>Ну вроде все предложения начинаются с большой буквы, а в конце точка <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" />.&nbsp; Почему никто не отвечает?:(</p>]]></content>
			<author>
				<name><![CDATA[tiim]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27991</uri>
			</author>
			<updated>2012-06-28T07:40:02Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=61251#p61251</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=60382#p60382" />
			<content type="html"><![CDATA[<p><span style="color: #008800"><strong>tiim</strong>, не забываем:</p><div class="quotebox"><blockquote><p>Предложения должны начинаться с большой буквы и заканчиваться точкой.</p></blockquote></div><p></span></p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2012-05-16T08:55:08Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=60382#p60382</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=60371#p60371" />
			<content type="html"><![CDATA[<p>Методом проб и ошибок накатал кое-что:):<br /></p><div class="codebox"><pre><code>SetFormat, float, 0.2 ; Количество нолей после точки
Gui, +Resize  
Gui, Add, Edit, x106 y119 w90 h20 gRes vA, 
Gui, Add, Edit, x106 y149 w90 h20 gRes vB, 
Gui, Add, Edit, x106 y179 w90 h20 vC,
Gui, Add, DropDownList, x106 y29 w90 h21 r2 vPower gRes, Р_акт||Р_реакт|
Gui, Add, DropDownList, x106 y59 w90 h21 r2 vFormula gRes, Формула1||Формула2|
Gui, Add, DropDownList, x106 y89 w90 h21 r2 vVariant gRes, Решение1||Решение2|
Gui, Add, ComboBox, x106 y209 w90 h21 r6 vItog gRes, Итог1|Итог2|Итог3|Итог4|Итог5|Итог6|
Gui, Add, Edit, x106 y239 w90 h21 vResult,
; Generated using SmartGUI Creator 4.0
Gui, Show, x144 y91 h318 w308, New GUI Window
Return

GuiClose:
ExitApp

return

Res:
gui, submit, nohide
If (Formula=&quot;Формула1&quot; and Power=&quot;Р_акт&quot; and Variant=&quot;Решение1&quot;)
{C:=A+B
    C1:=A+B
    C2:=(A+B)*0.1
    guicontrol,,Itog, |%C1%||%C2%
    R4:=Itog/100
    guicontrol,,Result, %R4%
    }
If (Formula=&quot;Формула2&quot; and Power=&quot;Р_акт&quot;)
{C:=A-B
    C1:=A-B
    C2:=(A-B)*10
    guicontrol,,Itog, |%C1%||%C2%
    }
If (Formula=&quot;Формула1&quot; and Power=&quot;Р_реакт&quot;)
    {C:=A/B
    C1:=A/B
    C2:=(A/B)*100
    guicontrol,,Itog, |%C1%||%C2%
    }
If (Formula=&quot;Формула2&quot; and Power=&quot;Р_реакт&quot;)
{C:=B/A
    C1:=B/A
    C2:=(B/A)*1000
    guicontrol,,Itog, |%C1%||%C2%
}
guicontrol,,C, %C%


return</code></pre></div><p>Только вот не пойму почему в combobox не меняется значение.</p>]]></content>
			<author>
				<name><![CDATA[tiim]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27991</uri>
			</author>
			<updated>2012-05-16T00:44:00Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=60371#p60371</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=60357#p60357" />
			<content type="html"><![CDATA[<p>Вот что мне нужно сделать, так навероное понятнее будет:<br /><a href="http://radikal.ru/F/s019.radikal.ru/i605/1205/16/ce867df10d1e.jpg.html"><span class="postimg"><img src="http://s019.radikal.ru/i605/1205/16/ce867df10d1et.jpg" alt="http://s019.radikal.ru/i605/1205/16/ce867df10d1et.jpg" /></span></a></p><div class="codebox"><pre><code>SetFormat, float, 0.2 ; Количество нолей после точки
Gui, Add, Edit, x106 y119 w90 h20 gRes vA, 
Gui, Add, Edit, x106 y149 w90 h20 gRes vB, 
Gui, Add, Edit, x106 y179 w90 h20 vC,
Gui, Add, DropDownList, x106 y29 w90 h21 r2 vPower gRes, Р_акт|Р_реакт|
Gui, Add, DropDownList, x106 y59 w90 h21 r2 vFormula gRes, Формула1|Формула2|
Gui, Add, DropDownList, x106 y89 w90 h21 r2 vVariant gRes, Решение1|Решение2|
Gui, Add, ComboBox, x106 y209 w90 h21 r6 vItog, Итог1|Итог2|Итог3|Итог4|Итог5|Итог6|
Gui, Add, Edit, x106 y239 w90 h21 vResult,
; Generated using SmartGUI Creator 4.0
Gui, Show, x144 y91 h318 w308, New GUI Window
Return

GuiClose:
ExitApp

return

Res:
gui, submit, nohide
If (Formula=&quot;Формула1&quot; and Power=&quot;Р_акт&quot; and Variant=&quot;Решение1&quot;)
{C:=A+B
    C1:=A+B
    C2:=(A+B)*0.1
    guicontrol,,Itog, |%C1%||%C2%
    }
If (Formula=&quot;Формула2&quot; and Power=&quot;Р_акт&quot;)
{C:=A-B
    C1:=A-B
    C2:=(A-B)*10
    guicontrol,,Itog, |%C1%||%C2%
    }
If (Formula=&quot;Формула1&quot; and Power=&quot;Р_реакт&quot;)
    {C:=A/B
    C1:=A/B
    C2:=(A/B)*100
    guicontrol,,Itog, |%C1%||%C2%
    }
If (Formula=&quot;Формула2&quot; and Power=&quot;Р_реакт&quot;)
{C:=B/A
    C1:=B/A
    C2:=(B/A)*1000
    guicontrol,,Itog, |%C1%||%C2%
}
guicontrol,,C, %C%


return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[tiim]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27991</uri>
			</author>
			<updated>2012-05-15T12:51:19Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=60357#p60357</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=60326#p60326" />
			<content type="html"><![CDATA[<p>Irbis, совершенно верно....выделил блоки и все работает....<br />А подскажите каким образом выбранное значение в Combobox использовать для дальнейших расчетов в формуле Cobmobox/100 и результат вывести в новом редактируемом поле ввода Edit.</p>]]></content>
			<author>
				<name><![CDATA[tiim]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27991</uri>
			</author>
			<updated>2012-05-14T14:40:51Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=60326#p60326</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=60311#p60311" />
			<content type="html"><![CDATA[<p>В скрипте не разбирался ,но навскидку видно, что блоки<strong> if... if... </strong>нужно выделять <br /></p><div class="codebox"><pre><code>If (Formula=&quot;Формула2&quot; and Power=&quot;Р_реакт&quot;)
{
    C:=B/A
    C1:=B/A
    C2:=(B/A)*1000
    guicontrol,,Itog, |%C1%|%C2%
}</code></pre></div><p>(AHK не поддерживает Python-style выделения блоков отступами, а жаль... Есть мысль поработать над этим, но нужно время <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" />)</p>]]></content>
			<author>
				<name><![CDATA[Irbis]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27384</uri>
			</author>
			<updated>2012-05-14T11:26:08Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=60311#p60311</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Как сложить данные ячеек]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=60308#p60308" />
			<content type="html"><![CDATA[<p>teadrinker, извиняюсь за не совсем понятный вопрос, как оказывается не всегда просто объяснить то что хочешь сделать:). То, что мне было нужно написал InFlames. В этом коде я попытался добавить еще одно условие:</p><div class="codebox"><pre><code>SetFormat, float, 0.2 ; Количество нолей после точки
Gui, Add, Edit, x106 y119 w90 h20 gRes vA, 
Gui, Add, Edit, x106 y149 w90 h20 gRes vB, 
Gui, Add, Edit, x106 y179 w90 h20 vC,
Gui, Add, DropDownList, x106 y29 w90 h21 r2 vPower, Р_акт|Р_реакт|
Gui, Add, DropDownList, x106 y59 w90 h21 r2 vFormula gRes, Формула1|Формула2|
Gui, Add, DropDownList, x106 y89 w90 h21 r2, Решение1|Решение2|
Gui, Add, ComboBox, x106 y209 w90 h21 r6 vItog, Итог1|Итог2|Итог3|Итог4|Итог5|Итог6|
; Generated using SmartGUI Creator 4.0
Gui, Show, x144 y91 h318 w308, New GUI Window
Return

GuiClose:
ExitApp

return

Res:
gui, submit, nohide
If (Formula=&quot;Формула1&quot; and Power=&quot;Р_акт&quot;)
              C:=A+B
    C1:=A+B
    C2:=(A+B)*0,1
    guicontrol,,Itog, |%C1%|%C2%
If (Formula=&quot;Формула2&quot; and Power=&quot;Р_акт&quot;)
              C:=A-B
    C1:=A-B
    C2:=(A-B)*10
    guicontrol,,Itog, |%C1%|%C2%
If (Formula=&quot;Формула1&quot; and Power=&quot;Р_реакт&quot;)
              C:=A/B
    C1:=A/B
    C2:=(A/B)*100
    guicontrol,,Itog, |%C1%|%C2%
If (Formula=&quot;Формула2&quot; and Power=&quot;Р_реакт&quot;)
    C:=B/A
    C1:=B/A
    C2:=(B/A)*1000
    guicontrol,,Itog, |%C1%|%C2%

guicontrol,,C, %C%


return</code></pre></div><p>Что-то не пойму как сделать так, чтобы в зависимости от выбранных значений Power и Formula в ComboBox попадали результаты вычислений. Данный код заносит в ComboBox вычисление по самым нижним формулам С1:=B/A, C2:=(B/A)*1000.</p>]]></content>
			<author>
				<name><![CDATA[tiim]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27991</uri>
			</author>
			<updated>2012-05-14T09:43:23Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=60308#p60308</id>
		</entry>
</feed>
