<?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=12947&amp;type=atom" />
	<updated>2017-09-03T12:48:11Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=12947</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Получить манифест файла]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=119113#p119113" />
			<content type="html"><![CDATA[<p>Спасибо. Все работает.</p>]]></content>
			<author>
				<name><![CDATA[Karagiozis]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=38736</uri>
			</author>
			<updated>2017-09-03T12:48:11Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=119113#p119113</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Получить манифест файла]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=119112#p119112" />
			<content type="html"><![CDATA[<p>Да, малость недоработал код. Надо размер ресурса узнавать, иначе StrGet залазит дальше положенного.<br /></p><div class="codebox"><pre><code>
File = D:\setup.exe
hFile := DllCall(&quot;LoadLibraryEx&quot;, &quot;str&quot;, File, &quot;ptr&quot;, 0, &quot;uint&quot;, 2, &quot;ptr&quot;)
hRsrc := DllCall(&quot;FindResource&quot;, &quot;ptr&quot;, hFile, &quot;ptr&quot;, 1, &quot;ptr&quot;, 24, &quot;ptr&quot;)
hData := DllCall(&quot;LoadResource&quot;, &quot;ptr&quot;, hFile, &quot;ptr&quot;, hRsrc, &quot;ptr&quot;)
pData := DllCall(&quot;LockResource&quot;, &quot;ptr&quot;, hData, &quot;ptr&quot;)
cbData := DllCall(&quot;SizeofResource&quot;, &quot;ptr&quot;, hFile, &quot;ptr&quot;, hRsrc)
Manifest := StrGet(pData, cbData, &quot;cp0&quot;)
DllCall(&quot;FreeLibrary&quot;, &quot;ptr&quot;, hFile)
MsgBox, %Manifest%
</code></pre></div>]]></content>
			<author>
				<name><![CDATA[YMP]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=81</uri>
			</author>
			<updated>2017-09-03T11:46:14Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=119112#p119112</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Получить манифест файла]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=119111#p119111" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>teadrinker пишет:</cite><blockquote><p>В вашем файле 0 байт.</p></blockquote></div><p>Очень странно, но у гугл диска проблема с этим файлом.<br />Обновил ссылку<br /><a href="https://www.dropbox.com/s/5r5wqtgdje68tpp/setup.exe?dl=0">https://www.dropbox.com/s/5r5wqtgdje68t … p.exe?dl=0</a></p>]]></content>
			<author>
				<name><![CDATA[Karagiozis]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=38736</uri>
			</author>
			<updated>2017-09-02T20:18:43Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=119111#p119111</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Получить манифест файла]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=119109#p119109" />
			<content type="html"><![CDATA[<p>В вашем файле 0 байт.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2017-09-02T16:35:09Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=119109#p119109</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Получить манифест файла]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=119107#p119107" />
			<content type="html"><![CDATA[<p>Помогите! Скрипт крашит, тоесть просто так сам процесс убивается когда пытается прочитать манифест кое-какого файла. Манифест там есть так как Resource Hacker спокойно видит его. <br />Крашит из-за этой строчки:<br /></p><div class="codebox"><pre><code>Manifest := StrGet(pData, &quot;cp0&quot;)</code></pre></div><p>Пробывал словить ошибку, но не помогает:<br /></p><div class="codebox"><pre><code>File = D:\setup.exe
hFile := DllCall(&quot;LoadLibraryEx&quot;, &quot;str&quot;, File, &quot;ptr&quot;, 0, &quot;uint&quot;, 2, &quot;ptr&quot;)
hRsrc := DllCall(&quot;FindResource&quot;, &quot;ptr&quot;, hFile, &quot;ptr&quot;, 1, &quot;ptr&quot;, 24, &quot;ptr&quot;)
hData := DllCall(&quot;LoadResource&quot;, &quot;ptr&quot;, hFile, &quot;ptr&quot;, hRsrc, &quot;ptr&quot;)
pData := DllCall(&quot;LockResource&quot;, &quot;ptr&quot;, hData, &quot;ptr&quot;)
try {
	Manifest := StrGet(pData, &quot;cp0&quot;) ; Крашит из-за этого
} catch e {
	msgbox, error
}
DllCall(&quot;FreeLibrary&quot;, &quot;ptr&quot;, hFile)
MsgBox, %Manifest%</code></pre></div><p>Вот сам файл:<br /><a href="https://www.dropbox.com/s/5r5wqtgdje68tpp/setup.exe?dl=0">https://www.dropbox.com/s/5r5wqtgdje68t … p.exe?dl=0</a></p>]]></content>
			<author>
				<name><![CDATA[Karagiozis]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=38736</uri>
			</author>
			<updated>2017-09-02T16:11:04Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=119107#p119107</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Получить манифест файла]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=118807#p118807" />
			<content type="html"><![CDATA[<p>Спасибо большое!</p>]]></content>
			<author>
				<name><![CDATA[Karagiozis]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=38736</uri>
			</author>
			<updated>2017-08-26T11:11:16Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=118807#p118807</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Получить манифест файла]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=118799#p118799" />
			<content type="html"><![CDATA[<p>Вот так можно:<br /></p><div class="codebox"><pre><code>
File = D:\Temp\Hello.exe
hFile := DllCall(&quot;LoadLibraryEx&quot;, &quot;str&quot;, File, &quot;ptr&quot;, 0, &quot;uint&quot;, 2, &quot;ptr&quot;)
hRsrc := DllCall(&quot;FindResource&quot;, &quot;ptr&quot;, hFile, &quot;ptr&quot;, 1, &quot;ptr&quot;, 24, &quot;ptr&quot;)
hData := DllCall(&quot;LoadResource&quot;, &quot;ptr&quot;, hFile, &quot;ptr&quot;, hRsrc, &quot;ptr&quot;)
pData := DllCall(&quot;LockResource&quot;, &quot;ptr&quot;, hData, &quot;ptr&quot;)
Manifest := StrGet(pData, &quot;cp0&quot;)
DllCall(&quot;FreeLibrary&quot;, &quot;ptr&quot;, hFile)
MsgBox, %Manifest%
</code></pre></div>]]></content>
			<author>
				<name><![CDATA[YMP]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=81</uri>
			</author>
			<updated>2017-08-26T08:05:32Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=118799#p118799</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: Получить манифест файла]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=118783#p118783" />
			<content type="html"><![CDATA[<p>Доброй ночи. Прошу вашей помощи. <br />Как можно получить и считать содержимое манифеста в файле если он есть как это делает Resource Hacker?<br />У скомпилированных ахк скриптов есть манифест. Хотелось бы считать содержимое манифеста любого скомпилированого ахк скрипта.<br />Я так понял что надо копать в сторону функций FindResource, но поиск привел меня только к извлечению иконок.</p>]]></content>
			<author>
				<name><![CDATA[Karagiozis]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=38736</uri>
			</author>
			<updated>2017-08-25T20:01:06Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=118783#p118783</id>
		</entry>
</feed>
