<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[Серый форум &mdash; AHK: Получение шестнадцатеричного числа из текста и наоборот.]]></title>
		<link>https://forum.script-coding.com/viewtopic.php?id=10944</link>
		<atom:link href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=10944&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[Недавние сообщения в теме «AHK: Получение шестнадцатеричного числа из текста и наоборот.».]]></description>
		<lastBuildDate>Sat, 12 Sep 2015 17:15:49 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: AHK: Получение шестнадцатеричного числа из текста и наоборот.]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=97384#p97384</link>
			<description><![CDATA[<p>Спасибо большое.</p>]]></description>
			<author><![CDATA[null@example.com (yalanne)]]></author>
			<pubDate>Sat, 12 Sep 2015 17:15:49 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=97384#p97384</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: Получение шестнадцатеричного числа из текста и наоборот.]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=97383#p97383</link>
			<description><![CDATA[<p>Или так:<br /></p><div class="codebox"><pre><code>text = ff
MsgBox % Format(&quot;{:#x}&quot;, &quot;0x&quot; text) + 0

hex = 0xff
MsgBox % Format(&quot;{:x}&quot;, hex)</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (serzh82saratov)]]></author>
			<pubDate>Sat, 12 Sep 2015 17:13:09 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=97383#p97383</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: Получение шестнадцатеричного числа из текста и наоборот.]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=97382#p97382</link>
			<description><![CDATA[<div class="codebox"><pre><code>msgbox % LTrim(0x50F,&quot;0x&quot;)</code></pre></div><p>Не знал что все так просто. <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /> Спасибо.</p><p>А может и для первой функции есть более легкий аналог?</p>]]></description>
			<author><![CDATA[null@example.com (yalanne)]]></author>
			<pubDate>Sat, 12 Sep 2015 17:11:09 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=97382#p97382</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: Получение шестнадцатеричного числа из текста и наоборот.]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=97381#p97381</link>
			<description><![CDATA[<p>А почему просто не прилепить или отрезать &quot;0x&quot;?</p>]]></description>
			<author><![CDATA[null@example.com (serzh82saratov)]]></author>
			<pubDate>Sat, 12 Sep 2015 17:04:25 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=97381#p97381</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: Получение шестнадцатеричного числа из текста и наоборот.]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=97380#p97380</link>
			<description><![CDATA[<p>В первой функции текст F05 конвертируется в 0xF05 с которой работают математические действия.( место F05 может быть любое hex число).</p><p>А во второй функции должно из 0xF05 быть ответом F05 в виде текста.<br />В этой функции просто перебираются байты от младшего значения и преобразуются в текст. После того как loop прошел все байты (5-0-F)&nbsp; он должен остановится, вот как только отловить старшее значение?</p>]]></description>
			<author><![CDATA[null@example.com (yalanne)]]></author>
			<pubDate>Sat, 12 Sep 2015 16:53:39 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=97380#p97380</guid>
		</item>
		<item>
			<title><![CDATA[Re: AHK: Получение шестнадцатеричного числа из текста и наоборот.]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=97379#p97379</link>
			<description><![CDATA[<p>Непонятно. Напишите примеры, было - стало.</p>]]></description>
			<author><![CDATA[null@example.com (serzh82saratov)]]></author>
			<pubDate>Sat, 12 Sep 2015 16:10:55 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=97379#p97379</guid>
		</item>
		<item>
			<title><![CDATA[AHK: Получение шестнадцатеричного числа из текста и наоборот.]]></title>
			<link>https://forum.script-coding.com/viewtopic.php?pid=97378#p97378</link>
			<description><![CDATA[<p>Что бы получить число из текста у меня получилось<br /></p><div class="fancy_spoiler_switcher"><div class="fancy_spoiler_switcher_header" data-lang-open="открыть спойлер" data-lang-close="скрыть спойлер"><strong>+</strong>&nbsp;открыть спойлер</div><div class="fancy_spoiler"><div class="codebox"><pre><code>SetFormat, IntegerFast, hex
GetHexInStr(String)
{
    hex := {1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15}
    loop,parse,String
        e+= (hex[A_LoopField]&lt;&lt;((StrLen(String)-A_Index)*4))
    return e
}

msgbox % GetHexInStr(&quot;50F&quot;) + 0</code></pre></div></div></div><p>А вот что бы наоборот, возникли трудности<br /></p><div class="fancy_spoiler_switcher"><div class="fancy_spoiler_switcher_header" data-lang-open="открыть спойлер" data-lang-close="скрыть спойлер"><strong>+</strong>&nbsp;открыть спойлер</div><div class="fancy_spoiler"><div class="codebox"><pre><code>SetFormat, IntegerFast, hex
GetStrInInt(Integer)
{
    hex := {0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,10:&quot;A&quot;,11:&quot;B&quot;,12:&quot;C&quot;,13:&quot;D&quot;,14:&quot;E&quot;,15:&quot;F&quot;}
    loop
        msgbox % hex[(Integer&gt;&gt;(A_Index-1)*4)&amp;0xF]
}


msgbox % GetStrInInt(0x50F)</code></pre></div></div></div><p>Проблема в том то что я не знаю как определить размер этого числа для остоновки цикла.</p>]]></description>
			<author><![CDATA[null@example.com (yalanne)]]></author>
			<pubDate>Sat, 12 Sep 2015 16:00:31 +0000</pubDate>
			<guid>https://forum.script-coding.com/viewtopic.php?pid=97378#p97378</guid>
		</item>
	</channel>
</rss>
