<?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: How to check if you&#8217;re running a debug swf</title>
	<atom:link href="http://michaelvandaniker.com/blog/2008/11/25/how-to-check-debug-swf/feed/" rel="self" type="application/rss+xml" />
	<link>http://michaelvandaniker.com/blog/2008/11/25/how-to-check-debug-swf/</link>
	<description>Data Visualization on the Flash Platform</description>
	<lastBuildDate>Tue, 11 May 2010 14:43:59 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
	<item>
		<title>By: judah</title>
		<link>http://michaelvandaniker.com/blog/2008/11/25/how-to-check-debug-swf/comment-page-1/#comment-7374</link>
		<dc:creator>judah</dc:creator>
		<pubDate>Tue, 11 May 2010 14:43:59 +0000</pubDate>
		<guid isPermaLink="false">http://michaelvandaniker.com/blog/?p=93#comment-7374</guid>
		<description>Calling:

isDebugSWF = new Error().getStackTrace().search(/:[0-9]+]$/m) &gt; -1;

can prevent your swf from loading in the release version of the Flash Player (not debug though). If you need to use it call it after the application has loaded and not in the constructor of your class.</description>
		<content:encoded><![CDATA[<p>Calling:</p>
<p>isDebugSWF = new Error().getStackTrace().search(/:[0-9]+]$/m) &gt; -1;</p>
<p>can prevent your swf from loading in the release version of the Flash Player (not debug though). If you need to use it call it after the application has loaded and not in the constructor of your class.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tek</title>
		<link>http://michaelvandaniker.com/blog/2008/11/25/how-to-check-debug-swf/comment-page-1/#comment-1260</link>
		<dc:creator>Tek</dc:creator>
		<pubDate>Tue, 07 Jul 2009 14:51:29 +0000</pubDate>
		<guid isPermaLink="false">http://michaelvandaniker.com/blog/?p=93#comment-1260</guid>
		<description>Sorry, my post : http://www.tekool.net/blog/2009/06/27/identifying-a-debug-or-release-swf-file-at-runtime/</description>
		<content:encoded><![CDATA[<p>Sorry, my post : <a href="http://www.tekool.net/blog/2009/06/27/identifying-a-debug-or-release-swf-file-at-runtime/" rel="nofollow">http://www.tekool.net/blog/2009/06/27/identifying-a-debug-or-release-swf-file-at-runtime/</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tek</title>
		<link>http://michaelvandaniker.com/blog/2008/11/25/how-to-check-debug-swf/comment-page-1/#comment-1259</link>
		<dc:creator>Tek</dc:creator>
		<pubDate>Tue, 07 Jul 2009 14:48:50 +0000</pubDate>
		<guid isPermaLink="false">http://michaelvandaniker.com/blog/?p=93#comment-1259</guid>
		<description>Hi, Thibault Imbert from www.bytearray.org redirects me here. I recently have posted a similar solution to this problem without finding this post first, sorry.

The solution I use is the same but had the idea to directly use new Error() to always have access to getStackTrace without to have to use a try...catch.

I implement it in my own apps with : 
public static const debug:Boolean = new Error().getStackTrace().search(/:[0-9]+]$/m) &gt; -1;</description>
		<content:encoded><![CDATA[<p>Hi, Thibault Imbert from <a href="http://www.bytearray.org" rel="nofollow">http://www.bytearray.org</a> redirects me here. I recently have posted a similar solution to this problem without finding this post first, sorry.</p>
<p>The solution I use is the same but had the idea to directly use new Error() to always have access to getStackTrace without to have to use a try&#8230;catch.</p>
<p>I implement it in my own apps with :<br />
public static const debug:Boolean = new Error().getStackTrace().search(/:[0-9]+]$/m) &gt; -1;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Igor</title>
		<link>http://michaelvandaniker.com/blog/2008/11/25/how-to-check-debug-swf/comment-page-1/#comment-180</link>
		<dc:creator>Igor</dc:creator>
		<pubDate>Wed, 01 Apr 2009 09:09:27 +0000</pubDate>
		<guid isPermaLink="false">http://michaelvandaniker.com/blog/?p=93#comment-180</guid>
		<description>I am usually debugging my apps localy and deploty them on site. in sutch case it&#039;s also possible to check if appication was runned locally.

package net.panellabs.utils
{
	public final class ApplicationPath
	{		
		public static var isLocal:Boolean;
		
		public static function init(SWFPath:String):void //ApplicationPath.init(loaderInfo.url);
		{
			if(SWFPath.indexOf(&quot;file:&quot;) &gt; -1)
			{
				isLocal = true;
			}
			else
			{
				isLocal = false;
			}
		}
	}
}</description>
		<content:encoded><![CDATA[<p>I am usually debugging my apps localy and deploty them on site. in sutch case it&#8217;s also possible to check if appication was runned locally.</p>
<p>package net.panellabs.utils<br />
{<br />
	public final class ApplicationPath<br />
	{<br />
		public static var isLocal:Boolean;</p>
<p>		public static function init(SWFPath:String):void //ApplicationPath.init(loaderInfo.url);<br />
		{<br />
			if(SWFPath.indexOf(&#8220;file:&#8221;) &gt; -1)<br />
			{<br />
				isLocal = true;<br />
			}<br />
			else<br />
			{<br />
				isLocal = false;<br />
			}<br />
		}<br />
	}<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: niklas wörmann</title>
		<link>http://michaelvandaniker.com/blog/2008/11/25/how-to-check-debug-swf/comment-page-1/#comment-82</link>
		<dc:creator>niklas wörmann</dc:creator>
		<pubDate>Tue, 25 Nov 2008 07:53:08 +0000</pubDate>
		<guid isPermaLink="false">http://michaelvandaniker.com/blog/?p=93#comment-82</guid>
		<description>I agree, quite useful &quot;bit of a hack&quot;</description>
		<content:encoded><![CDATA[<p>I agree, quite useful &#8220;bit of a hack&#8221;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: JesterXL</title>
		<link>http://michaelvandaniker.com/blog/2008/11/25/how-to-check-debug-swf/comment-page-1/#comment-80</link>
		<dc:creator>JesterXL</dc:creator>
		<pubDate>Tue, 25 Nov 2008 05:32:40 +0000</pubDate>
		<guid isPermaLink="false">http://michaelvandaniker.com/blog/?p=93#comment-80</guid>
		<description>Brilliant!</description>
		<content:encoded><![CDATA[<p>Brilliant!</p>
]]></content:encoded>
	</item>
</channel>
</rss>
