<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>
	Comments on: Recovering previous editor state	</title>
	<atom:link href="https://undocumentedmatlab.com/articles/recovering-previous-editor-state/feed" rel="self" type="application/rss+xml" />
	<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=recovering-previous-editor-state</link>
	<description>Professional Matlab consulting, development and training</description>
	<lastBuildDate>Mon, 10 Oct 2016 07:44:26 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.7.2</generator>
	<item>
		<title>
		By: Yair Altman		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-390401</link>

		<dc:creator><![CDATA[Yair Altman]]></dc:creator>
		<pubDate>Mon, 10 Oct 2016 07:44:26 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-390401</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-390381&quot;&gt;Hexler&lt;/a&gt;.

@Hexler - I believe that MATLAB_Editor_State.xml merely stores the states of the various folding blocks in the code of every m-file that you have ever opened in the Editor, not just those files that are currently open.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-390381">Hexler</a>.</p>
<p>@Hexler &#8211; I believe that MATLAB_Editor_State.xml merely stores the states of the various folding blocks in the code of every m-file that you have ever opened in the Editor, not just those files that are currently open.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Hexler		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-390381</link>

		<dc:creator><![CDATA[Hexler]]></dc:creator>
		<pubDate>Sun, 09 Oct 2016 23:14:27 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-390381</guid>

					<description><![CDATA[For some reason this didn&#039;t work for me. It had just stored 4 out of a bunch of tabs.
However, I found a list of files in MATLAB_Editor_State.xml. It looks like the tabs I was working on.]]></description>
			<content:encoded><![CDATA[<p>For some reason this didn&#8217;t work for me. It had just stored 4 out of a bunch of tabs.<br />
However, I found a list of files in MATLAB_Editor_State.xml. It looks like the tabs I was working on.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Oleg Shebanits		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-386021</link>

		<dc:creator><![CDATA[Oleg Shebanits]]></dc:creator>
		<pubDate>Fri, 19 Aug 2016 08:48:35 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-386021</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-371093&quot;&gt;Michael&lt;/a&gt;.

This is brilliant! Thank you so much!
Works in R2016a and much simpler than making functions etc.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-371093">Michael</a>.</p>
<p>This is brilliant! Thank you so much!<br />
Works in R2016a and much simpler than making functions etc.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Me		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-375805</link>

		<dc:creator><![CDATA[Me]]></dc:creator>
		<pubDate>Thu, 05 May 2016 20:46:02 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-375805</guid>

					<description><![CDATA[I wish there were more people like you in this world!
Saved a lot of my time!]]></description>
			<content:encoded><![CDATA[<p>I wish there were more people like you in this world!<br />
Saved a lot of my time!</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Martin WH		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-374668</link>

		<dc:creator><![CDATA[Martin WH]]></dc:creator>
		<pubDate>Tue, 19 Apr 2016 10:17:19 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-374668</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-371093&quot;&gt;Michael&lt;/a&gt;.

Great - thanks! This doesn&#039;t happen to me very often, but when it does, it&#039;s really annoying. Your script works fine in R2016a (Mac) by the way.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-371093">Michael</a>.</p>
<p>Great &#8211; thanks! This doesn&#8217;t happen to me very often, but when it does, it&#8217;s really annoying. Your script works fine in R2016a (Mac) by the way.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Michael		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-371093</link>

		<dc:creator><![CDATA[Michael]]></dc:creator>
		<pubDate>Fri, 04 Mar 2016 14:11:41 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-371093</guid>

					<description><![CDATA[Inspired by this post, I created a shortcut in Matlab with the following content:

&lt;pre lang=&quot;matlab&quot;&gt;
%parse XML file
xmlFiles    = xmlread([prefdir filesep &#039;MATLABDesktop.xml.prev&#039;]);
%Retrieve the &quot;clients&quot;
FileNodes   = xmlFiles.getElementsByTagName(&#039;Client&#039;);
%get the length of the FileNodes
nrFiles     = FileNodes.getLength;
%initialize Files
Files       = cell(nrFiles,1);
%initialize isFile
isFile      = zeros(nrFiles,1);
%Iterate over all Elements and check if it is a file.
for iNode = 0:nrFiles-1 % Java indexing.
    %Files
    Files{iNode+1} = char(FileNodes.item(iNode).getAttribute(&#039;Title&#039;));
    %check if the &quot;client&quot; is a file:
    isFile(iNode+1) = exist(Files{iNode+1},&#039;file&#039;) == 2 &amp;&amp; ~(strcmp(Files{iNode+1},&#039;Workspace&#039;));
end
%remove the other files:
MyFiles = Files(find(isFile));
%open the files in the editor:
edit(MyFiles{:});
&lt;/pre&gt;

So whenever I close my editor by accident, I click on the shortcut to retrieve the files. It works in R2013a for me - I did not check other versions.

BR Michael]]></description>
			<content:encoded><![CDATA[<p>Inspired by this post, I created a shortcut in Matlab with the following content:</p>
<pre lang="matlab">
%parse XML file
xmlFiles    = xmlread([prefdir filesep 'MATLABDesktop.xml.prev']);
%Retrieve the "clients"
FileNodes   = xmlFiles.getElementsByTagName('Client');
%get the length of the FileNodes
nrFiles     = FileNodes.getLength;
%initialize Files
Files       = cell(nrFiles,1);
%initialize isFile
isFile      = zeros(nrFiles,1);
%Iterate over all Elements and check if it is a file.
for iNode = 0:nrFiles-1 % Java indexing.
    %Files
    Files{iNode+1} = char(FileNodes.item(iNode).getAttribute('Title'));
    %check if the "client" is a file:
    isFile(iNode+1) = exist(Files{iNode+1},'file') == 2 &#038;& ~(strcmp(Files{iNode+1},'Workspace'));
end
%remove the other files:
MyFiles = Files(find(isFile));
%open the files in the editor:
edit(MyFiles{:});
</pre>
<p>So whenever I close my editor by accident, I click on the shortcut to retrieve the files. It works in R2013a for me &#8211; I did not check other versions.</p>
<p>BR Michael</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: DoTTy		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-361820</link>

		<dc:creator><![CDATA[DoTTy]]></dc:creator>
		<pubDate>Tue, 17 Nov 2015 15:45:38 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-361820</guid>

					<description><![CDATA[Thank you very much for this post, it saved my live!! ;) Regards]]></description>
			<content:encoded><![CDATA[<p>Thank you very much for this post, it saved my live!! 😉 Regards</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Noam Greenboim		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-350045</link>

		<dc:creator><![CDATA[Noam Greenboim]]></dc:creator>
		<pubDate>Wed, 27 May 2015 15:57:20 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-350045</guid>

					<description><![CDATA[Thanks for posting this, I have the same issue every now and then.]]></description>
			<content:encoded><![CDATA[<p>Thanks for posting this, I have the same issue every now and then.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Eric Melonakos		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-343940</link>

		<dc:creator><![CDATA[Eric Melonakos]]></dc:creator>
		<pubDate>Mon, 12 Jan 2015 22:30:41 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-343940</guid>

					<description><![CDATA[Thank you! This just saved me a ton of time and confusion!]]></description>
			<content:encoded><![CDATA[<p>Thank you! This just saved me a ton of time and confusion!</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: cw		</title>
		<link>https://undocumentedmatlab.com/articles/recovering-previous-editor-state#comment-331856</link>

		<dc:creator><![CDATA[cw]]></dc:creator>
		<pubDate>Thu, 18 Sep 2014 22:02:16 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=2656#comment-331856</guid>

					<description><![CDATA[This is pretty much one of the most useful posts I&#039;ve encountered in a very long time. Thank you !]]></description>
			<content:encoded><![CDATA[<p>This is pretty much one of the most useful posts I&#8217;ve encountered in a very long time. Thank you !</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
