<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; AHK: редактирование файла excel не открывая его]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=16692&amp;type=atom" />
	<updated>2021-10-28T17:45:01Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=16692</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: редактирование файла excel не открывая его]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=150289#p150289" />
			<content type="html"><![CDATA[<p><strong>inseption86</strong>, <strong>teadrinker</strong> спасибо Вам! Работает как часы! <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /></p><div class="codebox"><pre><code>book := xl.workbooks.Open(path)</code></pre></div><p>Я уже использовал подобный код, но он прямо открывал документ. Я не знал что использовав это в связке с командой закрытия, документ не будет явно открываться.</p>]]></content>
			<author>
				<name><![CDATA[CyberGudini]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=42079</uri>
			</author>
			<updated>2021-10-28T17:45:01Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=150289#p150289</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: редактирование файла excel не открывая его]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=150287#p150287" />
			<content type="html"><![CDATA[<p><strong>teadrinker</strong><br />Проще, спс.</p>]]></content>
			<author>
				<name><![CDATA[inseption86]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=38818</uri>
			</author>
			<updated>2021-10-28T17:08:13Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=150287#p150287</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: редактирование файла excel не открывая его]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=150286#p150286" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>inseption86 пишет:</cite><blockquote><div class="codebox"><pre><code>path := % A_Desktop &quot;\1.xlsx&quot;</code></pre></div></blockquote></div><p>Зачем здесь знак процента?<br /></p><div class="quotebox"><cite>inseption86 пишет:</cite><blockquote><div class="codebox"><pre><code>book.save
book.close(false)</code></pre></div></blockquote></div><p>А не проще<br /></p><div class="codebox"><pre><code>book.close(true)</code></pre></div><p>?</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2021-10-28T17:03:56Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=150286#p150286</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: редактирование файла excel не открывая его]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=150282#p150282" />
			<content type="html"><![CDATA[<p><strong>CyberGudini</strong><br /></p><div class="codebox"><pre><code>
xl := ComObjCreate(&quot;Excel.Application&quot;)
path := A_Desktop &quot;\1.xlsx&quot;
book := xl.workbooks.Open(path)
book.worksheets(1).Range(&quot;A2&quot;).Value := &quot;56&quot;

book.close(true)
xl.quit
ExitApp</code></pre></div>]]></content>
			<author>
				<name><![CDATA[inseption86]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=38818</uri>
			</author>
			<updated>2021-10-28T16:28:15Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=150282#p150282</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: редактирование файла excel не открывая его]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=150276#p150276" />
			<content type="html"><![CDATA[<p>Наверно сохранить изменения надо и закрыть oWorkbook, иначе она у вас так открытой и останется.<br /><a href="https://docs.microsoft.com/en-us/office/vba/api/excel.workbook.close">Workbook.Close method</a></p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2021-10-28T15:41:24Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=150276#p150276</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: редактирование файла excel не открывая его]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=150274#p150274" />
			<content type="html"><![CDATA[<p><strong>teadrinker</strong> Извините. Исправил. <br /><strong>teadrinker</strong> Подскажите пожалуйста как решить проблему. <img src="//forum.script-coding.com/img/smilies/roll.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[CyberGudini]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=42079</uri>
			</author>
			<updated>2021-10-28T15:21:05Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=150274#p150274</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: редактирование файла excel не открывая его]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=150269#p150269" />
			<content type="html"><![CDATA[<p><strong>CyberGudini</strong>, напоминаю о необходимости ставить точки в конце предложений. Исправьтесь и не грешите больше.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2021-10-28T14:31:14Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=150269#p150269</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[AHK: редактирование файла excel не открывая его]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=150268#p150268" />
			<content type="html"><![CDATA[<p>Я могу прочитать закрытый документ:<br /></p><div class="codebox"><pre><code>
FilePath := &quot;D:\123.xlsx&quot;	; specify your path here
oWorkbook := ComObjGet(FilePath)
CellF6Value := oWorkbook.Worksheets(&quot;Лист1&quot;).Range(&quot;A2&quot;).Value

MsgBox, % CellF6Value
</code></pre></div><p>Но вот когда пытаюсь его изменять ничего не происходит:<br /></p><div class="codebox"><pre><code>
FilePath := &quot;D:\123.xlsx&quot;	; specify your path here
oWorkbook := ComObjGet(FilePath)
oWorkbook.Worksheets(&quot;Лист1&quot;).Range(&quot;A2&quot;).Value := &quot;56&quot;
</code></pre></div><p>Почему? И как исправить? Подскажите&nbsp; пожалуйста.</p>]]></content>
			<author>
				<name><![CDATA[CyberGudini]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=42079</uri>
			</author>
			<updated>2021-10-28T14:06:41Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=150268#p150268</id>
		</entry>
</feed>
