<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Shedding Some Light &#187; Standards</title>
	<atom:link href="http://rickschummer.com/blog2/tag/standards/feed/" rel="self" type="application/rss+xml" />
	<link>http://rickschummer.com/blog2</link>
	<description>Shedding some light on topics of software development, Visual FoxPro, saving our planet, paying it forward, and anything else I find important enough to share.</description>
	<lastBuildDate>Thu, 19 Mar 2026 20:55:26 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.3</generator>
		<item>
		<title>VFP: File and folders via indirection</title>
		<link>http://rickschummer.com/blog2/2008/12/vfp-file-and-folders-via-indirection/</link>
		<comments>http://rickschummer.com/blog2/2008/12/vfp-file-and-folders-via-indirection/#comments</comments>
		<pubDate>Tue, 09 Dec 2008 17:22:00 +0000</pubDate>
		<dc:creator>Rick Schummer</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[Standards]]></category>
		<category><![CDATA[VFP]]></category>

		<guid isPermaLink="false">http://rickschummer.com/blog2/2008/12/vfp-file-and-folders-via-indirection/</guid>
		<description><![CDATA[Last night one of my clients was implementing their vertical market application half way around the world. The onsite support people were reporting an error when the app was started: &#8220;Invalid path or file name.&#8221; Thanks to the new error handler we implemented in the app I tracked this problem down to a single line [...]]]></description>
			<content:encoded><![CDATA[<p>Last night one of my clients was implementing their vertical market application half way around the world. The onsite support people were reporting an error when the app was started: &#8220;Invalid path or file name.&#8221;</p>
<p>Thanks to the new error handler we implemented in the app I tracked this problem down to a single line of code:</p>
<p><span style="font-size:85%;"><span style="font-family:courier new;">CD &#038;lcDataPath;</span></span></p>
<p>Looking at the value of lcDataPath it became instantly apparent what the problem was, spaces in the folder name. The tech support person right away explained to me the standard for the install is no spaces in the folder names. This site deviated from the standard folder name recommended by my customer. Now she knows exactly why the original developers proclaimed this &#8220;requirement&#8221; years ago.</p>
<p>I have not been burned by spaces in code for a long time because I always use indirection in my code whenever I deal with file names or folders.</p>
<p><span style="font-size:85%;"><span style="font-family:courier new;">CD (lcDataPath)</span><br /><span style="font-family:courier new;">USE (lcFileName) IN 0 SHARED AGAIN</span><br /><span style="font-family:courier new;">DELETE FILE (lcFileName)</span></span></p>
<p>I posted this issue on Twitter earlier today and Andrew MacNeill noted this is probably a great rule to add to <a target="_blank" href="http://www.codeplex.com/VFPX/Wiki/View.aspx?title=Code%20Analyst&amp;referringTitle=Home">Code Analyst</a> up on <a target="_blank" href="http://www.codeplex.com/VFPX">VFPX</a>. I agree. I am now curious how many developers do not test their applications in folder structures with spaces in the name. I just checked my development machine and all my test folders are space free. But I do install my applications on a virtual machine in the Program Files folders and this tests out the space problem.</p>
<p>Yet one more reason why we have <a target="_blank" href="http://www.whitelightcomputing.com/resources/WLCDeveloperGuidelines4point0.pdf">standards</a> at White Light Computing and why the adoption of industry best practices gives us more solid deployments and apps in production. Fortunately the onsite tech people were okay with renaming the folder, otherwise my customer would have been hiring us to review the application for other macro expansion gotchas.</p>
]]></content:encoded>
			<wfw:commentRss>http://rickschummer.com/blog2/2008/12/vfp-file-and-folders-via-indirection/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
