<?xml version="1.0"?>
<rss version="2.0">
	<channel>
		<title>How to search for files</title>
		<link>http://www.allegro.cc/forums/view/590511</link>
		<description>Allegro.cc Forum Thread</description>
		<webMaster>matthew@allegro.cc (Matthew Leverton)</webMaster>
		<lastBuildDate>Tue, 13 Mar 2007 05:44:23 +0000</lastBuildDate>
	</channel>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>How should I go about searching for different files in a directory, such as all files of one extension, without user input?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Kikaru)</author>
		<pubDate>Mon, 12 Mar 2007 20:10:13 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p><span class="source-code"><a href="http://www.allegro.cc/manual/al_findfirst" target="_blank"><span class="a">al_findfirst</span></a>, <a href="http://www.allegro.cc/manual/al_findnext" target="_blank"><span class="a">al_findnext</span></a>, <a href="http://www.allegro.cc/manual/al_findclose" target="_blank"><span class="a">al_findclose</span></a>, <a href="http://www.allegro.cc/manual/for_each_file_ex" target="_blank"><span class="a">for_each_file_ex</span></a> ...</span>
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (CGamesPlay)</author>
		<pubDate>Mon, 12 Mar 2007 20:18:10 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Thanks. Just one last question: with <tt>for_each_file_ex</tt>, is it possible to limit it to one directory, such as the same one as the .exe?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Kikaru)</author>
		<pubDate>Mon, 12 Mar 2007 23:59:44 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Yes. It doesn&#39;t recurse into subdirectories in the first place.</p><p><span class="source-code"><a href="http://www.allegro.cc/manual/replace_filename" target="_blank"><span class="a">replace_filename</span></a>, <a href="http://www.allegro.cc/manual/get_executable_name" target="_blank"><span class="a">get_executable_name</span></a></span>
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (CGamesPlay)</author>
		<pubDate>Tue, 13 Mar 2007 00:14:05 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Ok. Thanks. So, to find <tt>.sav</tt> files in a folder named <tt>SAVES</tt> in the directory as my game, I would do this:
</p><div class="source-code snippet"><div class="inner"><pre><a href="http://www.allegro.cc/manual/for_each_file_ex" target="_blank"><span class="a">for_each_file_ex</span></a><span class="k2">(</span><span class="s">"SAVES//*.sav"</span>, ..., my_callback, ...<span class="k2">)</span><span class="k2">;</span>
</pre></div></div><p>?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Kikaru)</author>
		<pubDate>Tue, 13 Mar 2007 00:24:35 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
for_each_file_ex(&quot;SAVES//*.sav&quot;, ..., my_callback, ...);
</p></div></div><p>

Yes, except that you would specify the directory as &quot;SAVES/*.sav&quot; (or under DOS/Windows &quot;SAVES\*.sav&quot;).
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (LennyLen)</author>
		<pubDate>Tue, 13 Mar 2007 00:30:16 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Oh. Yeah, I use windows and forgot which way the slashes went. <img src="http://www.allegro.cc/forums/smileys/grin.gif" alt=";D" /></p><p>Thanks for the help! <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Kikaru)</author>
		<pubDate>Tue, 13 Mar 2007 02:37:38 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>You might as well use /. It&#39;s more readable IMO because it doesn&#39;t require escaping, and it is cross-platform (unlike \).
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (BAF)</author>
		<pubDate>Tue, 13 Mar 2007 05:40:31 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>&#39;\\&#39; is for windows. I don&#39;t think &#39;/&#39; works on windows though. <img src="http://www.allegro.cc/forums/smileys/tongue.gif" alt=":P" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Kikaru)</author>
		<pubDate>Tue, 13 Mar 2007 05:41:46 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I don&#39;t think &#39;/&#39; works on windows though
</p></div></div><p>

Yes it does.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (LennyLen)</author>
		<pubDate>Tue, 13 Mar 2007 05:44:23 +0000</pubDate>
	</item>
</rss>
