<?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>Eric Fickes &#187; development</title>
	<atom:link href="http://ericfickes.com/category/development/feed/" rel="self" type="application/rss+xml" />
	<link>http://ericfickes.com</link>
	<description>Design minded Internet Programmer</description>
	<lastBuildDate>Fri, 28 Oct 2011 04:14:43 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Use INFORMATION_SCHEMA to find data about your database</title>
		<link>http://ericfickes.com/2011/02/find-out-data-about-your-database-with-system-views/</link>
		<comments>http://ericfickes.com/2011/02/find-out-data-about-your-database-with-system-views/#comments</comments>
		<pubDate>Mon, 21 Feb 2011 21:29:23 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[database]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[internets]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[automation]]></category>
		<category><![CDATA[data discovery]]></category>
		<category><![CDATA[db2]]></category>
		<category><![CDATA[information_schema]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[rdmbs]]></category>
		<category><![CDATA[schemata]]></category>
		<category><![CDATA[sql server]]></category>
		<category><![CDATA[sql-92]]></category>
		<category><![CDATA[SQLSERVER]]></category>
		<category><![CDATA[system tables]]></category>
		<category><![CDATA[system views]]></category>
		<category><![CDATA[tsql]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=2062</guid>
		<description><![CDATA[Have you ever been in this situation?  You&#8217;re the new developer for a database powered application and you have to figure out what tables contain a specific column?  Or maybe you&#8217;ve got a legacy database that needs it&#8217;s stored procedures &#8230; <a href="http://ericfickes.com/2011/02/find-out-data-about-your-database-with-system-views/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Have you ever been in this situation?  You&#8217;re the new developer for a database powered application and you have to figure out what tables contain a specific column?  Or maybe you&#8217;ve got a legacy database that needs it&#8217;s stored procedures and user defined functions cleaned up?  Or perhaps you&#8217;ve been assigned a unique database inventory task that requires you to report on the structure of your database, rather than the contents of your database.  Besides cracking open your favorite SQL editor and clicking through your database by hand, you might find the data you need from your database&#8217;s INFORMATION_SCHEMA System View.</p>
<p>All of the RDMS systems I&#8217;ve worked with have built in System Views ( or tables ) that contain data about the structure and contents of your database.  These views are there to help you with non data tasks.  For the sake of this post we&#8217;re only going mention the INFORMATION_SCHEMA, which is the system view I use most in SQL Server, and MySQL.  For your reference, here are links to INFORMATION_SCHEMA docs for four popular RDMS systems.</p>
<ol>
<li>SQL Server &#8211; <a title="SQL Server INFORMATION_SCHEMA" href="http://msdn.microsoft.com/en-us/library/ms186778.aspx" target="_blank">http://msdn.microsoft.com/en-us/library/ms186778.aspx</a></li>
<li>MySQL &#8211; <a title="MySQL INFORMATION_SCHEMA" href="http://dev.mysql.com/doc/refman/5.5/en/information-schema.html" target="_blank">http://dev.mysql.com/doc/refman/5.5/en/information-schema.html</a></li>
<li>Oracle &#8211; <a title="Oracle INFORMATION_SCHEMA" href="http://download.oracle.com/docs/cd/E17952_01/refman-5.0-en/information-schema.html" target="_blank">http://download.oracle.com/docs/cd/E17952_01/refman-5.0-en/information-schema.html</a></li>
<li>DB2 &#8211; <a title="DB2 INFORMATION_SCHEMA" href="http://www.tar.hu/sqlbible/sqlbible0100.html" target="_blank">http://www.tar.hu/sqlbible/sqlbible0100.html</a></li>
</ol>
<p>If you work with SQL Server, you&#8217;ll be happy to know you can see all of the System Views in Management Studio by default.</p>
<div id="attachment_2065" class="wp-caption aligncenter" style="width: 419px"><a href="http://ericfickes.com/wp-content/uploads/2011/02/AdventureWorks-SystemViews.png" rel="lightbox[2062]"><img class="size-full wp-image-2065" title="AdventureWorks-SystemViews" src="http://ericfickes.com/wp-content/uploads/2011/02/AdventureWorks-SystemViews.png" alt="SQL Server Management Studio shows all System Views" width="409" height="461" /></a><p class="wp-caption-text">System Views in the AdventureWorks database</p></div>
<p>If you work with MySQL, you can see the INFORMATION_SCHEMA database in MySQL Workbench, but you&#8217;ll have to enable it in Preferences first.</p>
<div id="attachment_2066" class="wp-caption aligncenter" style="width: 610px"><a href="http://ericfickes.com/wp-content/uploads/2011/02/mysql-ShowMetadataSchemata.png" rel="lightbox[2062]"><img class="size-medium wp-image-2066   " title="mysql-ShowMetadataSchemata" src="http://ericfickes.com/wp-content/uploads/2011/02/mysql-ShowMetadataSchemata-300x146.png" alt="" width="600" height="293" /></a><p class="wp-caption-text">Edit &gt; Preferences &gt; SQL Editor &gt; Check &#39;Show Metadata Schemata&#39;</p></div>
<p>Now for the MySQL users, turning on the Metadata Schemata is <em>not</em> required in order to query those system tables.  Assuming your user has appropriate permissions, you can always fire up Workbench and fire a query like this.</p>
<pre class="brush: sql; title: ; notranslate">
SELECT *
FROM INFORMATION_SCHEMA.Columns
WHERE Column_Name LIKE '%user%'
</pre>
<div id="attachment_2069" class="wp-caption aligncenter" style="width: 432px"><a href="http://ericfickes.com/wp-content/uploads/2011/02/mysql-has-info-schemas.png" rel="lightbox[2062]"><img class="size-full wp-image-2069" title="mysql-has-info-schemas" src="http://ericfickes.com/wp-content/uploads/2011/02/mysql-has-info-schemas.png" alt="" width="422" height="469" /></a><p class="wp-caption-text">MySQL has INFORMATION_SCHEMA tables too!</p></div>
<p>Now that you know about INFORMATION_SCHEMA, you should be happy to know this is part of the SQL-92 standard.  Which means whatever sql scripts you write in MySQL, will most likely work with SQL Server as well.  So go ahead and start querying your database, you&#8217;ll probably find uses for the INFORMATION_SCHEMA in your daily life really quickly.</p>
<p>I&#8217;m going to assume you&#8217;ve got the general idea here, so here are a few sql scripts that I&#8217;ve used over the years.  The first three are informational queries, and the last three are stored procedures that generate .NET or Coldfusion code based off of a table name.</p>
<p><strong>Find all tables with the column EmployeeID</strong></p>
<pre class="brush: sql; title: ; notranslate">
SELECT	*
FROM	INFORMATION_SCHEMA.COLUMNS
WHERE	COLUMN_NAME LIKE 'EmployeeID'
</pre>
<div id="attachment_2072" class="wp-caption aligncenter" style="width: 478px"><a href="http://ericfickes.com/wp-content/uploads/2011/02/1-which-tables-contain-columnName.png" rel="lightbox[2062]"><img class="size-full wp-image-2072" title="1-which-tables-contain-columnName" src="http://ericfickes.com/wp-content/uploads/2011/02/1-which-tables-contain-columnName.png" alt="" width="468" height="236" /></a><p class="wp-caption-text">Which tables have an EmployeeID column?</p></div>
<p><strong>How many tables have the word employee in the name</strong></p>
<pre class="brush: sql; title: ; notranslate">
SELECT	*
FROM	INFORMATION_SCHEMA.TABLES
WHERE	LOWER(TABLE_NAME) LIKE '%employee%'
</pre>
<div id="attachment_2073" class="wp-caption aligncenter" style="width: 483px"><a href="http://ericfickes.com/wp-content/uploads/2011/02/2-which-tables-are-named.png" rel="lightbox[2062]"><img class="size-full wp-image-2073" title="2-which-tables-are-named" src="http://ericfickes.com/wp-content/uploads/2011/02/2-which-tables-are-named.png" alt="" width="473" height="183" /></a><p class="wp-caption-text">How many %employee% tables are in the DB?</p></div>
<p><strong>How many SPROCs and UDFs does our database contain?</strong></p>
<pre class="brush: sql; title: ; notranslate">
SELECT	s.SPROCs, f.UDFs
FROM
(
	SELECT	COUNT(ROUTINE_NAME) AS 'SPROCs', NULL AS 'UDFs'
	FROM	INFORMATION_SCHEMA.ROUTINES
	WHERE	ROUTINE_TYPE = 'PROCEDURE'
) AS s,
(
	SELECT	NULL AS 'SPROCs', COUNT(ROUTINE_NAME) AS 'UDFs'
	FROM	INFORMATION_SCHEMA.ROUTINES
	WHERE	ROUTINE_TYPE = 'FUNCTION'
) AS f
</pre>
<div id="attachment_2076" class="wp-caption aligncenter" style="width: 159px"><a href="http://ericfickes.com/wp-content/uploads/2011/02/3-how-many-sprocs-udfs.png" rel="lightbox[2062]"><img class="size-full wp-image-2076" title="3-how-many-sprocs-udfs" src="http://ericfickes.com/wp-content/uploads/2011/02/3-how-many-sprocs-udfs.png" alt="" width="149" height="65" /></a><p class="wp-caption-text">How many stored procedures and user defined functions are in the DB?</p></div>
<p>The stored procedures listed below all accept an incoming table name, then reads data from INFORMATION_SCHEMA to generate code for the specified database table.  Instead of listing the raw SQL, I&#8217;m just showing a sample result and allowing you to download the raw SQL sprocs.</p>
<p><strong>Generate C# ADO.NET to VO Stored Procedure</strong></p>
<div id="attachment_2077" class="wp-caption aligncenter" style="width: 583px"><a href="http://ericfickes.com/wp-content/uploads/2011/02/4-create-sproc-generateGetTableCode.png" rel="lightbox[2062]"><img class="size-full wp-image-2077" title="4-create-sproc-generateGetTableCode" src="http://ericfickes.com/wp-content/uploads/2011/02/4-create-sproc-generateGetTableCode.png" alt="" width="573" height="458" /></a><p class="wp-caption-text">Build custom C# ADO.NET to custom VO fillerup code</p></div>
<p><a title="Download 'Generate C# ADO.NET to VO' Stored Procedure" href="http://ericfickes.com/code/INFO_SCHEMA/DotNet-generateGetTableCode.sql" target="_blank">download stored procedure</a></p>
<p><a title="Download 'Generate C# ADO.NET to VO' Stored Procedure" href="http://ericfickes.com/code/INFO_SCHEMA/DotNet-generateGetTableCode.sql" target="_blank"></a><br />
<strong>Generate .NET VO class Stored Procedure</strong></p>
<p><a href="http://ericfickes.com/wp-content/uploads/2011/02/5-create-sproc-generateTableVoClass.png" rel="lightbox[2062]"><img class="aligncenter size-full wp-image-2078" title="5-create-sproc-generateTableVoClass" src="http://ericfickes.com/wp-content/uploads/2011/02/5-create-sproc-generateTableVoClass.png" alt="Generate C# VO class for DB table name" width="315" height="454" /></a></p>
<p><a title="Download 'Generate .NET VO class' stored procedure" href="http://ericfickes.com/code/INFO_SCHEMA/DotNet-generateTableVoClass.sql" target="_blank">download stored procedure</a></p>
<p><strong>Generate Coldfusion CFFunction with CFQUERY Stored Procedure</strong></p>
<div id="attachment_2079" class="wp-caption aligncenter" style="width: 502px"><a href="http://ericfickes.com/wp-content/uploads/2011/02/6-create-sproc-MakeSelectFromDbTable.png" rel="lightbox[2062]"><img class="size-full wp-image-2079" title="6-create-sproc-MakeSelectFromDbTable" src="http://ericfickes.com/wp-content/uploads/2011/02/6-create-sproc-MakeSelectFromDbTable.png" alt="" width="492" height="276" /></a><p class="wp-caption-text">Generate Coldfusion CFFunction with CFQUERY for specified table name</p></div>
<p><a title="Download 'Generate Coldfusion CFFunction with CFQUERY' stored procedure" href="http://ericfickes.com/code/INFO_SCHEMA/Coldfusion-MakeSelectFromDbTable.sql" target="_blank">download stored procedure</a></p>
<p>I use these System Views almost daily, and there are a lot of scenarios where my job would take a lot longer to do if I didn&#8217;t know about this information.  The INFORMATION_SCHEMA also feeds my passion to build code that makes code, just love it.  Hopefully this nickel tour was enough information to help somebody out.</p>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2011/02/find-out-data-about-your-database-with-system-views/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
<enclosure url="http://ericfickes.com/code/INFO_SCHEMA/DotNet-generateGetTableCode.sql" length="17232" type="audio/mpeg" />
		</item>
		<item>
		<title>An aggregate may not appear in the set list of an UPDATE statement</title>
		<link>http://ericfickes.com/2011/02/an-aggregate-may-not-appear-in-the-set-list-of-an-update-statement/</link>
		<comments>http://ericfickes.com/2011/02/an-aggregate-may-not-appear-in-the-set-list-of-an-update-statement/#comments</comments>
		<pubDate>Mon, 21 Feb 2011 06:43:00 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[database]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[internets]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[tips and tricks]]></category>
		<category><![CDATA[tsql]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=1998</guid>
		<description><![CDATA[Ever seen the error &#8220;An aggregate may not appear in the set list of an UPDATE statement&#8221; when working with SQL Server?  I ran into this one recently after trying to put a COUNT in an UPDATE statement.  I was rewriting &#8230; <a href="http://ericfickes.com/2011/02/an-aggregate-may-not-appear-in-the-set-list-of-an-update-statement/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Ever seen the error &#8220;An aggregate may not appear in the set list of an UPDATE statement&#8221; when working with SQL Server?  I ran into this one recently after trying to put a COUNT in an UPDATE statement.  I was rewriting some legacy code to use a stored procedure, and it turned out to be the perfect case for a <a title="Read about Temporary Tables on MSDN" href="http://msdn.microsoft.com/en-us/library/ms177399.aspx" target="_blank">Temporary Table</a>.</p>
<p>Instead of boring you with a work scenario, let&#8217;s take a simpler one that uses the <a title="Download Microsoft's AdventureWorks database from this site so you can play along at home" href="http://msftdbprodsamples.codeplex.com/releases/view/37109" target="_blank">AdventureWorks</a> database.  This example will create a list of sales people, total order count for each person, and store this list a single table variable to be used as the final data table.</p>
<p>Should be three simple steps right?</p>
<h2>1. Create @Table variable</h2>
<pre class="brush: sql; title: ; notranslate">
DECLARE @SalesPeople TABLE
(
  EmployeeID int NOT NULL,
  SalesPersonID int NOT NULL,
  FullName varchar(200) NOT NULL,
  Title varchar(200) NOT NULL,
  sales_count int NULL default 0
)
</pre>
<h2>2. INSERT sales people into @Table</h2>
<pre class="brush: sql; title: ; notranslate">
-- HACKISH : Match SalesPersonID to EmployeeID, and fill @SalesPeople
INSERT INTO @SalesPeople
( EmployeeID, SalesPersonID, FullName, Title )
SELECT	e.EmployeeID, sp.SalesPersonID,
		c.FirstName + ' ' + c.LastName as FullName,
		e.Title
FROM	Sales.SalesPerson sp,
		HumanResources.Employee e,
		Person.Contact c
WHERE	sp.SalesPersonID = e.EmployeeID
AND		e.ContactID = c.ContactID
</pre>
<h2>3. UPDATE @Table with COUNT</h2>
<pre class="brush: sql; title: ; notranslate">
UPDATE	@SalesPeople
SET
	sales_count = COUNT( soh.SalesOrderID )
FROM	@SalesPeople sp, Sales.SalesOrderHeader soh
WHERE EXISTS (
	SELECT DISTINCT SalesPersonID FROM @SalesPeople WHERE SalesPersonID = soh.SalesPersonID
)
AND	sp.SalesPersonID = soh.SalesPersonID
</pre>
<div id="attachment_2004" class="wp-caption alignnone" style="width: 775px"><a style="font-weight: normal;" href="http://ericfickes.com/wp-content/uploads/2011/02/aggregate-error.png" rel="lightbox[1998]"><img title="aggregate-error" src="http://ericfickes.com/wp-content/uploads/2011/02/aggregate-error.png" alt="" width="765" height="187" /></a><p class="wp-caption-text">Not COUNT allowed in an UPDATE SET statement</p></div>
<p>The third step is where the original error comes in, so let&#8217;s update this to four steps and see how a Table Variable gets through this.</p>
<h2>1 &amp; 2 &#8211; Repeat from above</h2>
<h2>3. Create Table Variable of order counts</h2>
<pre class="brush: sql; title: ; notranslate">
SELECT	soh.SalesPersonID, COUNT( soh.SalesOrderID ) AS sales_count
INTO	#SalesOrderCounts
FROM	Sales.SalesOrderHeader soh
WHERE EXISTS (
	SELECT DISTINCT SalesPersonID FROM @SalesPeople WHERE SalesPersonID = soh.SalesPersonID
)
GROUP BY soh.SalesPersonID
</pre>
<h2>4. Update @Table with order counts</h2>
<pre class="brush: sql; title: ; notranslate">
UPDATE	@SalesPeople
SET		sales_count = tmp.sales_count
FROM	@SalesPeople sp, #SalesOrderCounts tmp
WHERE	sp.SalesPersonID = tmp.SalesPersonID
</pre>
<p>And here&#8217;s the full script from start to finish with the table variable in use.</p>
<pre class="brush: sql; title: ; notranslate">
-- Master table of sales people
DECLARE @SalesPeople TABLE
(
  EmployeeID int NOT NULL,
  SalesPersonID int NOT NULL,
  FullName varchar(200) NOT NULL,
  Title varchar(200) NOT NULL,
  sales_count int NULL default 0
)

-- Match SalesPersonID to EmployeeID, and fill @SalesPeople
INSERT INTO @SalesPeople
( EmployeeID, SalesPersonID, FullName, Title )
SELECT	e.EmployeeID, sp.SalesPersonID,
		c.FirstName + ' ' + c.LastName as FullName,
		e.Title
FROM	Sales.SalesPerson sp, HumanResources.Employee e, Person.Contact c
WHERE	sp.SalesPersonID = e.EmployeeID
AND		e.ContactID = c.ContactID

-- put sales counts into the other kind of #tableVariable
SELECT	soh.SalesPersonID, COUNT( soh.SalesOrderID ) AS sales_count
INTO	#SalesOrderCounts
FROM	Sales.SalesOrderHeader soh
WHERE EXISTS (
	SELECT DISTINCT SalesPersonID FROM @SalesPeople WHERE SalesPersonID = soh.SalesPersonID
)
GROUP BY soh.SalesPersonID

-- Update our master @table with data from #tableVariable
UPDATE	@SalesPeople
SET		sales_count = tmp.sales_count
FROM	@SalesPeople sp, #SalesOrderCounts tmp
WHERE	sp.SalesPersonID = tmp.SalesPersonID

-- dump the results
SELECT	FullName, Title, sales_count
FROM	@SalesPeople

-- cleanup
drop table #SalesOrderCounts
</pre>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2011/02/an-aggregate-may-not-appear-in-the-set-list-of-an-update-statement/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Injecting javascript into asp.net via code</title>
		<link>http://ericfickes.com/2011/02/injecting-javascript-into-asp-net-via-code/</link>
		<comments>http://ericfickes.com/2011/02/injecting-javascript-into-asp-net-via-code/#comments</comments>
		<pubDate>Sat, 19 Feb 2011 04:13:50 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[.net]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[tips and tricks]]></category>
		<category><![CDATA[asp.net]]></category>
		<category><![CDATA[aspx]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[Literal]]></category>
		<category><![CDATA[msdn]]></category>
		<category><![CDATA[postback]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=1903</guid>
		<description><![CDATA[Microsoft has a great MSDN article on using javascript along asp.net, but they didn&#8217;t mention a technique I like to use, put it in a Literal control.  While there are many ways to add javascript to a page, I find &#8230; <a href="http://ericfickes.com/2011/02/injecting-javascript-into-asp-net-via-code/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Microsoft has a great MSDN article on <a title="Several other techniques for using javascript with asp.net" href="http://msdn.microsoft.com/en-us/library/aa479011.aspx" target="_blank">using javascript along asp.net</a>, but they didn&#8217;t mention a technique I like to use, put it in a <a title="ASP.NET Literal Class" href="http://msdn.microsoft.com/en-us/library/f0aw4d5w.aspx" target="_blank">Literal</a> control.  While there are many ways to add javascript to a page, I find putting the javascript in a literal much less stressful.  Using a Literal control placeholder is also a good way to add messaging to a page after postback, but we&#8217;re just going to look at adding javascript.</p>
<p>Let&#8217;s take a simple example.  Say you&#8217;ve got a comment form that you want to auto close, or reload after the form was posted.  Below is a simple single file style asp.net page with a simple javascript function that reloads this page.</p>
<pre class="brush: csharp; title: ; notranslate">
&lt;%@ Page Language=&quot;C#&quot; %&gt;

&lt;script runat=&quot;server&quot;&gt;
/// &lt;summary&gt;
/// &lt;/summary&gt;
/// &lt;param name=&quot;sender&quot;&gt;&lt;/param&gt;
/// &lt;param name=&quot;e&quot;&gt;&lt;/param&gt;
protected void Page_Load(object sender, EventArgs e)
{
    if (!IsPostBack)
    {

    }
}

///////////////////////////////////////////////////////////////////////////////
/// Do stuff with the form data, then refresh page using javascript
protected void submitComments(object sender, EventArgs e)
{

    try
    {
	//
	// do stuff here
	//

	// set javascript timer to reload page afer 3 seconds
	js_target.Text = &quot;setTimeout('reload()', 3000);&quot;;

    }
    catch (Exception exc)
    {
        Response.Write( &quot;ERROR : &quot; + exc.Message );
    }
}
&lt;/script&gt;

&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;&gt;

&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; &gt;
&lt;head&gt;
	&lt;title&gt;Comments&lt;/title&gt;
	&lt;script type=&quot;text/javascript&quot;&gt;
	// page reload helper
	function reload() {
		document.location.replace( document.location );
	}
	&lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;

&lt;form id=&quot;form1&quot; runat=&quot;server&quot; method=&quot;post&quot;&gt;

&lt;script type=&quot;text/javascript&quot;&gt;&lt;asp:Literal runat=&quot;server&quot; id=&quot;js_target&quot; /&gt;&lt;/script&gt;

	Comments
	&lt;asp:TextBox runat=&quot;server&quot; ID=&quot;comment_box&quot; Width=&quot;200&quot; /&gt;
	&lt;br&gt;&lt;br&gt;

	Your name
	&lt;asp:TextBox runat=&quot;server&quot; ID=&quot;fullname&quot; Width=&quot;200&quot; /&gt;
	&lt;br&gt;&lt;br&gt;
	&lt;asp:Button runat=&quot;server&quot; ID=&quot;submit_btn&quot; onclick=&quot;submitComment&quot; Text=&quot;submit&quot; /&gt;

&lt;/form&gt;
&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>If you look just under the form tag you&#8217;ll see the key to this technique, an asp literal wrapped by an open and close script tag.</p>
<pre class="brush: jscript; title: ; notranslate">
&lt;script type=&quot;text/javascript&quot;&gt;&lt;asp:Literal runat=&quot;server&quot; id=&quot;js_target&quot; /&gt;&lt;/script&gt;
</pre>
<p>When you load your page and view the source you&#8217;ll just see an empty script tag, so it shouldn&#8217;t interfere with the execution or rendering of your page.</p>
<p>The last part of this technique is simple, in your server code just set your Literal control&#8217;s .Text value to your javascript code.  In this case when I post my comment form, after handling the input data I display a thank you message, then set some javascript to reload the page.</p>
<pre class="brush: csharp; title: ; notranslate">
ltl_js.Text = &quot;setTimeout('reload()', 3000);&quot;;
</pre>
<p>That&#8217;s all there is to it.  Drop a literal in an empty script block and BAM!, you have an easy way to add javascript to your asp.net page.</p>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2011/02/injecting-javascript-into-asp-net-via-code/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Today I took 30 minutes to save hours</title>
		<link>http://ericfickes.com/2011/01/today-i-took-30-minutes-to-save-hours/</link>
		<comments>http://ericfickes.com/2011/01/today-i-took-30-minutes-to-save-hours/#comments</comments>
		<pubDate>Tue, 04 Jan 2011 04:21:41 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[database]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[tips and tricks]]></category>
		<category><![CDATA[automation]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[bat]]></category>
		<category><![CDATA[batch]]></category>
		<category><![CDATA[batch file]]></category>
		<category><![CDATA[cli]]></category>
		<category><![CDATA[cmd]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[cursor]]></category>
		<category><![CDATA[DECLARE]]></category>
		<category><![CDATA[del]]></category>
		<category><![CDATA[exec]]></category>
		<category><![CDATA[fetch]]></category>
		<category><![CDATA[fetch_status]]></category>
		<category><![CDATA[information_schema]]></category>
		<category><![CDATA[kill]]></category>
		<category><![CDATA[restore]]></category>
		<category><![CDATA[sproc]]></category>
		<category><![CDATA[sqlcmd]]></category>
		<category><![CDATA[sys]]></category>
		<category><![CDATA[tsql]]></category>
		<category><![CDATA[workflow]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=1861</guid>
		<description><![CDATA[UPDATE &#8211; 1/6/2011 : Since writing this post I have bundled this entire reset process into a single windows batch file. In addition to restoring my database, I also have to remove temp files from my server, so it was &#8230; <a href="http://ericfickes.com/2011/01/today-i-took-30-minutes-to-save-hours/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><strong> </strong><strong>UPDATE &#8211; </strong><strong>1/6/2011 : </strong>Since writing this post I have bundled this entire reset process into a single <a title="How to use windows batch files" href="http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/batch.mspx?mfr=true" target="_blank">windows batch file</a>. In addition to restoring my database, I also have to remove temp files from my server, so it was time to go command line with all of this.</p>
<p>Here the contents of my batch file.</p>
<pre class="brush: plain; title: ; notranslate">
### DELETE TEMP FILES
del /q /f /s Z:\_FavoriteClient\_GIT_\webapp\invoices\* /f /s

### RESTORE DATABASE
sqlcmd -S &quot;localhost&quot; -i Z:\_FavoriteClient\_GIT_\sql\restoreBackup.sql
</pre>
<p>To use this in a .bat file, copy and paste the text into Notepad, then save as &#8220;restore.bat&#8221;.  Remember, you will need to wrap your filename.bat with quotes, otherwise Notepad will save the file as filename.bat.txt.</p>
<p>* The contents of restoreBackup.sql is listed below.</p>
<hr style="color: efefef;" size="1" noshade="noshade" />One of my favorite pastimes as a programmer is writing code that writes code, aka workflow automation.  It&#8217;s not something I do on every project, but I&#8217;ve been doing a lot of SQL Server development recently, and I&#8217;ve been having a lot of fun using the <a title="SQL 2008 RS Information Schema Views (Transact-SQL)" href="http://msdn.microsoft.com/en-us/library/ms186778.aspx" target="_blank">INFORMATION_SCHEMA views</a> to <a title="Use TSQL to generate Actionscript VO classes" href="http://ericfickes.posterous.com/tsql-sproc-generatetablevoclass" target="_blank">build VO classes</a>, forms representing tables, or just finding what tables have a specific column.  Today I took a 30 minute trip to the <a title="SQL 2008 SYS tables" href="http://msdn.microsoft.com/en-us/library/ms187406.aspx" target="_blank">SYS side</a> and wrote a tsql script that will save me hours.</p>
<p>The web application I&#8217;m working on is a payment processor made up of five steps.  In order to test I have to setup multiple sales for multiple clients, then log in as three different admin users to push the transactions through the system.  This gets my test transactions to the proper testable state.  The process of setting up testable transactions takes over 30 clicks, and once I hit step 3 of the wizard, my test transactions are completed in a way that I have to re-setup the test data ( 20 GOTO 10 ).</p>
<p>I thought about a handful of options, and ended up going with this solution.</p>
<ol>
<li>Setup all test transactions in web application by hand ( get the data ready )</li>
<li>Take a full database backup ( freeze the data )</li>
<li>Use TSQL script to drop all connections to my app&#8217;s db, then restore the database to the &#8220;testable&#8221; state from step 1 ( reset the DB )</li>
</ol>
<p>Here is my TSQL script</p>
<pre class="brush: sql; title: ; notranslate">
DECLARE @sessID int,
		@dbName varchar(50),
		@userName varchar(50),
		@backupFile varchar(200)

SET @dbName		= 'DA413'	-- your database name
SET @userName	= 'DA413'	-- sql user account to look for
SET @backupFile = 'D:\DB\Backup\DA413.bak' -- path to SQL backup file

-- use a cursor to store all session_ids
DECLARE session_cursor CURSOR
FOR
	SELECT	session_id
	FROM	sys.dm_exec_sessions
	WHERE	original_login_name = @userName

	-- open cursor and grab first row
	OPEN session_cursor
	FETCH NEXT FROM session_cursor INTO @sessID

	-- loop through session_ids
	WHILE @@FETCH_STATUS = 0
	BEGIN

		-- kill it
		-- using EXEC because the sproc kill does not like @variables
		EXEC('kill ' + @sessID)

		-- get the next session_id
		FETCH NEXT FROM session_cursor INTO @sessID
	END

-- cursor cleanup
CLOSE session_cursor
DEALLOCATE session_cursor

-- restore backup
USE master
	RESTORE DATABASE DA413
	FROM DISK = @backupFile
GO
</pre>
<p>A few notes about this script :</p>
<ul>
<li>I only need to disconnect my web application&#8217;s database user, not any user</li>
<li>I&#8217;m using the latest full backup, and not a specific database snapshot</li>
<li>The SPROC <a title="TSQL KILL sproc" href="http://technet.microsoft.com/en-us/library/ms173730.aspx" target="_blank">kill</a> doesn&#8217;t like @variables as input, so use <a title="TSQL EXEC" href="http://msdn.microsoft.com/en-us/library/ms188332.aspx" target="_blank">EXEC</a></li>
<li>Your web server doesn&#8217;t know the user was disconnected, so you&#8217;ll have to log back into your application.</li>
<li>If you use this technique, be sure to RERUN your backup if you add anything to the database ( EX : new table column, stored procedure, etc )</li>
<li>If you&#8217;re not the only person connected to this database, make sure you don&#8217;t disconnect anybody else using the same database name</li>
</ul>
<p>This solution is perfect for me because I have full control over my code, database, and server.  It&#8217;s also great because I can test my application, run a single sql script, and 10 seconds later I can test my application again.  While this solution is perfect for me, it&#8217;s probably best used as reference for others.  However, this technique of rolling back the database could be applied to <em>any</em> software application using SQL Server for it&#8217;s datasource.</p>
<p>Hope this helps somebody.</p>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2011/01/today-i-took-30-minutes-to-save-hours/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Coldfusion 7 peer not authenticated error</title>
		<link>http://ericfickes.com/2010/12/coldfusion-7-peer-not-authenticated-error/</link>
		<comments>http://ericfickes.com/2010/12/coldfusion-7-peer-not-authenticated-error/#comments</comments>
		<pubDate>Fri, 31 Dec 2010 01:08:37 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[adobe]]></category>
		<category><![CDATA[coldfusion]]></category>
		<category><![CDATA[development]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=1846</guid>
		<description><![CDATA[Have you ever seen the error message &#8220;ErrorDetail I/O Exception: peer not authenticated&#8221; when working with Coldfusion 7&#8242;s CFHTTP?  I hadn&#8217;t until recently, and it turns out I found an interesting bug with Coldfusion7 running on top of Windows 2003. &#8230; <a href="http://ericfickes.com/2010/12/coldfusion-7-peer-not-authenticated-error/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Have you ever seen the error message &#8220;ErrorDetail I/O Exception: peer not authenticated&#8221; when working with Coldfusion 7&#8242;s CFHTTP?  I hadn&#8217;t until recently, and it turns out I found an interesting bug with Coldfusion7 running on top of Windows 2003.</p>
<p>I ran into this while building a PayPal payment processor, and wasted too much time thinking this was a username and password issue, or possibly a problem with the host name I was using, but it wasn&#8217;t.  It was extra frustrating because my test PayPal code worked just fine if I created an html form and posted directly to PayPal.  Also, the same code worked perfectly in production, just not on my development server.</p>
<p>After hours of googling and trial and error I found <em>my</em> solution thanks to <a title="USING KEYTOOL TO IMPORT SSL CERTIFICATES INTO SUN JDK" href="http://www.talkingtree.com/blog/index.cfm/2004/7/1/keytool" target="_blank">Steve Erat</a>.  Basically Coldfusion 7 isn&#8217;t able to handshake securely with PayPal ( Verisign ) because the server doesn&#8217;t have PayPal&#8217;s certificate in the key store.  You can read in depth about what&#8217;s happening on<a title="Coldfusion7 MX peer not authenticated error" href="http://www.talkingtree.com/blog/index.cfm/2004/7/1/keytool" target="_blank"> Steve&#8217;s blog post here</a>.</p>
<p>So my solution ended up being this</p>
<ol>
<li>Download the verisign.cer certificate from my production server</li>
<li>Import verisign.cer into the JDK that comes with Coldfusion</li>
<li>Restart Coldfusion and IIS</li>
</ol>
<p>I tried all sorts of things from installing every windows certificate management features, upgrading my JDK and having Coldfusion use that, apply all the latest service packs and updates to my server, changing any paypal setting I can think of.  All I needed to do was this.</p>
<ol>
<li>Drop to CMD prompt</li>
<li>Run the keytool that came installed with Coldfusion<small><br />
&#8220;C:\CFusionMX7\runtime\jre\bin\keytool -import -trustcacerts -keystore C:\CFusionMX7\runtime\jre\lib\security\cacerts -storepass changeit -noprompt -alias PayPal -file c:\verisign.cer&#8221;</small></li>
</ol>
<p>I couldn&#8217;t find this solution anywhere else online besides Steve&#8217;s site, so this is a rebroadcast in case somebody else hits this issue.  Also, at the time of writing, the test payment hostname for PayPal is pilot-payflowpro.paypal.com.</p>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2010/12/coldfusion-7-peer-not-authenticated-error/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PayPal test credit card numbers</title>
		<link>http://ericfickes.com/2010/12/paypal-test-credit-card-numbers/</link>
		<comments>http://ericfickes.com/2010/12/paypal-test-credit-card-numbers/#comments</comments>
		<pubDate>Tue, 28 Dec 2010 17:49:56 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[development]]></category>
		<category><![CDATA[internets]]></category>
		<category><![CDATA[tips and tricks]]></category>
		<category><![CDATA[credit card]]></category>
		<category><![CDATA[paypal]]></category>
		<category><![CDATA[testing]]></category>

		<guid isPermaLink="false">http://ericfickes.posterous.com/paypal-test-credit-card-numbers</guid>
		<description><![CDATA[Test Credit Card Account Numbers While testing, use only the credit card numbers listed here. Other numbers produce an error. Expiration Date must be a valid date in the future (use the mmyy format). Test Credit Card Account Numbers Credit Card &#8230; <a href="http://ericfickes.com/2010/12/paypal-test-credit-card-numbers/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><!--[CDATA[</p>
<div style="font-family: Arial; font-size: medium;" mce_style="font-family: Arial; font-size: medium;"-->
<h1 style="color: #800000; font-family: Arial, sans-serif; font-size: 16pt; line-height: 18pt; font-weight: bold; font-style: normal; border-bottom-style: solid; margin-bottom: 16pt; margin-right: 1pt; border-bottom-width: 1px;">Test Credit Card Account Numbers</h1>
<p style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">While testing, use only the credit card numbers listed here. Other numbers produce an error.</p>
<p style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;"><span style="font-weight: bold;"><strong>Expiration Date</strong></span></p>
<p>must be a valid date in the future (use the <span style="font-weight: bold;"><strong>mmyy</strong></span> format).</p>
<h2 style="color: #800000; font-size: 14pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 16pt; font-weight: bold; font-style: normal;">Test Credit Card Account Numbers</h2>
<table class="whs1" style="border-collapse: separate;" border="1">
<tbody>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt; font-weight: bold;">Credit Card Type</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt; font-weight: bold;">Credit Card Number</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">American Express</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">378282246310005</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">American Express</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">371449635398431</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">American Express Corporate</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">378734493671000</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Australian BankCard</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">5610591081018250</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Diners Club</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">30569309025904</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Diners Club</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">38520000023237</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Discover</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">6011111111111117</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Discover</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">6011000990139424</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">JCB</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">3530111333300000</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">JCB</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">3566002020360505</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">MasterCard</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">5555555555554444</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">MasterCard</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">5105105105105100</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Visa</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">4111111111111111</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Visa</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">4012888888881881</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Visa</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">4222222222222</p>
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;"><em><span style="font-style: normal; font-weight: bold;"><strong>Note</strong></span></em><strong> :</strong> Even though this number has a different character count than the other test numbers, it is the correct and functional number.</p>
</td>
</tr>
<tr>
<td class="whs6" colspan="2">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Processor-specific Cards</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Dankort (PBS)</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">76009244561</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Dankort (PBS)</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">5019717010103742</p>
</td>
</tr>
<tr>
<td class="whs4" width="248px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">Switch/Solo (Paymentech)</p>
</td>
<td class="whs5" width="363px">
<p class="CellBody" style="margin-top: 1pt; font-size: 10pt; font-family: Arial, sans-serif; margin-bottom: 6pt; line-height: 13pt; margin-right: 1pt;">6331101999990016</p>
</td>
</tr>
</tbody>
</table>
<div><span style="font-family: Arial; font-size: medium;">** This information is a rebroadcast of </span><a href="http://www.paypalobjects.com/en_US/vhelp/paypalmanager_help/credit_card_numbers.htm">http://www.paypalobjects.com/en_US/vhelp/paypalmanager_help/credit_card_numbers.htm</a></div>
<p><a href="http://ericfickes.posterous.com/paypal-test-credit-card-numbers">Permalink</a></p>
<p>| <a href="http://ericfickes.posterous.com/paypal-test-credit-card-numbers#comment">Leave a comment</a></p>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2010/12/paypal-test-credit-card-numbers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Endless Mural wins FWA site of the day</title>
		<link>http://ericfickes.com/2010/11/endless-mural-wins-fwa-site-of-the-day/</link>
		<comments>http://ericfickes.com/2010/11/endless-mural-wins-fwa-site-of-the-day/#comments</comments>
		<pubDate>Sat, 20 Nov 2010 06:55:25 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[.net]]></category>
		<category><![CDATA[art]]></category>
		<category><![CDATA[award]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[cool]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[fun]]></category>
		<category><![CDATA[Internet Explorer]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[Visual Studio]]></category>
		<category><![CDATA[asp.net]]></category>
		<category><![CDATA[azure]]></category>
		<category><![CDATA[beauty of the web]]></category>
		<category><![CDATA[branden hall]]></category>
		<category><![CDATA[cloud]]></category>
		<category><![CDATA[endlessmural]]></category>
		<category><![CDATA[FixDBLib]]></category>
		<category><![CDATA[generative art]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[ie9]]></category>
		<category><![CDATA[joshua davis]]></category>
		<category><![CDATA[okapi]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=1750</guid>
		<description><![CDATA[I&#8217;m ecstatic to announce the Endless Mural HTML5 project has won the prestigious FWA Site of the day award.  While this isn&#8217;t the first project I&#8217;ve worked on that has won the FWA, it is the first NON-Flash, HTML5 and &#8230; <a href="http://ericfickes.com/2010/11/endless-mural-wins-fwa-site-of-the-day/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<div id="attachment_1822" class="wp-caption aligncenter" style="width: 610px"><a title="Endless Mural wins FWA SOTD, and we didn't even use Flash!" href="http://www.thefwa.com/site/the-endless-mural" target="_blank"><img class="size-full wp-image-1822 " style="border: 0px initial initial;" title="Endless Mural &gt; FWA site of the day" src="http://ericfickes.com/wp-content/uploads/2010/11/endlessmural-fwa.png" alt="FWA Site of the day &gt; Nov 22 2010" width="600" height="395" /></a><p class="wp-caption-text">Endless Mural wins FWA for HTML5</p></div>
<p>I&#8217;m ecstatic to announce the Endless Mural HTML5 project has won the prestigious <a title="Endless Mural wins the FWA Site of the day award" href="http://www.thefwa.com/site/the-endless-mural" target="_blank">FWA Site of the day award</a>.  While this isn&#8217;t the first project I&#8217;ve worked on that has <a title="Wiretree.com has kicked out a handful of FWAs.  Because they're that good" href="http://thefwa.com/profile/wiretree" target="_blank">won the FWA</a>, it is the first NON-Flash, HTML5 and ASP.NET project that has.  No Flash, and we still got the FWA site of the day, SWEET!.</p>
<h1>I need a SQL Ninja</h1>
<div>
<p>On Friday July 23rd I got the chance to skateboard with my good buddy and personal hero <a title="Joshua Davis Studios" href="http://joshuadavis.com" target="_blank">Joshua Davis</a>.  I feel lucky being able to say we&#8217;ve actually been skating together for a few years now, but this was certainly my favorite session we&#8217;ve had so far.  We started out at <a title="Broomfield Skatepark pictures on sk8colorado.blogspot.com" href="http://sk8colorado.blogspot.com/2010/07/broomfield-skatepark.html" target="_blank">Broomfield&#8217;s new park</a> because I had to show Josh the new mini bowl.</p>
<div id="attachment_1762" class="wp-caption aligncenter" style="width: 235px"><a href="http://ericfickes.com/wp-content/uploads/2010/11/josh-eric-skate-checkin.jpg" rel="lightbox[1750]"><img class="size-medium wp-image-1762" title="Joshua Davis and Eric Fickes" src="http://ericfickes.com/wp-content/uploads/2010/11/josh-eric-skate-checkin-225x300.jpg" alt="skate or fry" width="225" height="300" /></a><p class="wp-caption-text">Two hot dogs ( http://yfrog.com/n3hs5j )</p></div>
<p>After Broomfield we made a quick stop for lunch, and then on to the Denver Skatepark in downtown.  It was great showing Josh the lines at my hometown skateparks, as well as a few radical maneuvers.</p>
<p>Now that Josh had seen my non-frontside airs, it was time to wrap things up.  As we were saying our goodbyes I decided to ask about work.  Normally I don&#8217;t talk about work at the skatepark, but I was thinking about going indie again, and figured what the heck.</p>
<p>Turns out Josh was about to start a project for <a title="Endless Mural &gt; Part of the IE9 launch project 'Beauty of the Web'" href="http://www.beautyoftheweb.com" target="_blank">Microsoft</a> ( WHAT?!?! ) and he need to &#8220;find a SQL Ninja&#8221; ( DOUBLE WHAT?!?! ).  I&#8217;ve been actively working with MS SQL Server since version 6.5, so I let him know he was looking at his sql ninja.  Josh was interested, but gave me the &#8220;just cause we&#8217;re bros, doesn&#8217;t put you on the team&#8221;.</p>
<h1>HTML5 drawing tool in one night</h1>
<p>Driving home from the skatepark I called my wife super giddy.  &#8221;Honey, I may be going indie sooner than we planned&#8221;.  I gave her the rundown of the potential project Josh and I just spoke about, and let her know I had some homework to do.  That night I went home and built out a distant cousin of the endless mural project.</p>
<div style="clear: both;">
<div id="attachment_1781" class="wp-caption alignleft" style="width: 243px"><a href="http://ericfickes.com/wp-content/uploads/2010/11/efdraw-html5.png" rel="lightbox[1750]"><img class="size-medium wp-image-1781" title="EFDRAW" src="http://ericfickes.com/wp-content/uploads/2010/11/efdraw-html5-233x300.png" alt="You can draw with HTML5" width="233" height="300" /></a><p class="wp-caption-text">HTML5 drawing tool powered by ASPX and MySQL</p></div>
<div id="attachment_1782" class="wp-caption alignright" style="width: 244px"><a href="http://ericfickes.com/wp-content/uploads/2010/11/efdraw-skull.png" rel="lightbox[1750]"><img class="size-medium wp-image-1782" title="draw save and share" src="http://ericfickes.com/wp-content/uploads/2010/11/efdraw-skull-234x300.png" alt="sloppy html5 drawing" width="234" height="300" /></a><p class="wp-caption-text">HTML5 drawing tool powered by ASPX and MySQL</p></div>
</div>
</div>
<p><a title="I built an HTML5 drawing tool overnight" href="http://fickii.com/efdraw/" target="_blank">EFDRAW</a> is a really simple HTML5 drawing tool powered by ASP.NET and MySQL.  It has most of the features of the mural ( draw, save, replay, share ), but this was only a proof of concept.  This was my first dive into HTML5 development, and it&#8217;s pretty sweet.</p>
<p><object id="stU0hSREFIR1FfQFVcU1tYV1dV" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="425" height="344" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="data" value="http://www.screentoaster.com/swf/STPlayer.swf" /><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="flashvars" value="video=stU0hSREFIR1FfQFVcU1tYV1dV" /><param name="src" value="http://www.screentoaster.com/swf/STPlayer.swf" /><param name="allowfullscreen" value="true" /><embed id="stU0hSREFIR1FfQFVcU1tYV1dV" type="application/x-shockwave-flash" width="425" height="344" src="http://www.screentoaster.com/swf/STPlayer.swf" flashvars="video=stU0hSREFIR1FfQFVcU1tYV1dV" allowscriptaccess="always" allowfullscreen="true" data="http://www.screentoaster.com/swf/STPlayer.swf"></embed></object></p>
<p>If you&#8217;re interested in HTML5 drawing tools, feel free to play around with <a title="I bult an HTML5 drawing tool overnight" href="http://fickii.com/efdraw/" target="_blank">EFDRAW</a>, view source, help yourself.</p>
<h1>There&#8217;s one thing&#8230;. Azure</h1>
<p>A few days after building EFDRAW my band <a href="http://twitter.com/#!/thecompilers/status/20575513102" target="_blank">The Compilers</a> played at Ignite Denver 7.  Right before starting our first set my phone rings and it&#8217;s Josh!  OMG I think, this is either the &#8220;you got it&#8221; or the &#8220;sorry bud, we&#8217;ll skate again&#8221; call.  I decide to take the call even though we were locked and loaded, standing on stage with our gear waiting for the house music to go down.  I answer and it&#8217;s Josh, but not the usual hyperactive Josh I&#8217;m accustomed to.  I ask about the gig and he says &#8220;Well, there&#8217;s one thing.  We have to use Azure&#8221;.</p>
<p>I let him know I&#8217;ve worked with other cloud platforms already, just not Microsoft&#8217;s.  So we talk a little more and Josh passes the phone to Branden so we can talk 0s and 1s.  After talking to Branden &#8220;mega brain&#8221; Hall for a few minutes he asks if I can do this.  I tell him yes, he says yes, I get excited, he gets excited.  Branden passed me back to Josh and I&#8217;m in shock at this point.</p>
<h1>Now the boring stuff</h1>
<p>So that&#8217;s the story of how I landed the Endless Mural gig, now the boring technical details.</p>
<p>The drawing portion of the mural was built by <a title="Branden Hall's personal website" href="http://waxpraxis.org" target="_blank">Branden Hall</a> of <a title="Automata Studios :: Branden Hall's software company" href="http://automatastudios.com" target="_blank">Automata Studios</a>.  I did the backend which is made up of ASP.NET ( C# ), SQL Azure, and Windows Azure.  We&#8217;re using Azure blob storage to save and serve up the PNGs created at the mural.  To access SQL server, I wrote a super lightweight data access library using all native .NET.</p>
<p>For the most part the backend was very much like every other .NET SQL Server project I build, but Azure did introduce a few gotchas.</p>
<ol>
<li>The publishing and management of your cloud site mainly goes through <a title="Windows Azure control panel" href="http://windows.azure.com/" target="_blank">http://windows.azure.com/</a>.</li>
<li>You can deploy your site from Visual Studio which proved to be immensely helpful after my Azure deploy package grew beyond 100 MB.</li>
<li>You can access SQL Azure directly from SQL 2008+ management tools.</li>
<li>You can not FTP single files up to the cloud, only the full ball of wax.</li>
<li>You can still use web.config for configuration storage, but Azure also has it&#8217;s own version of web.config.</li>
<li>If you need to edit your settings after deploying, store those settings in your Azure service config, not web.config</li>
<li>SQL Azure requires all tables to use clustered indexes</li>
<li>SQL Azure has it&#8217;s own TSQL restrictions ( not many, but be aware )</li>
<li>On average, doing a full republish of an Azure site took a full hour.</li>
</ol>
<p>I could probably ramble on and on about Azure, but I&#8217;ll cut it short.  If you happen to have any questions about Azure feel free to hit me up or leave a comment.  I would also like to say that I <em>know</em> Microsoft is and has been actively improving Azure by the day.  The state of Azure today is most likely even better than when we built the mural, so my experiences may not be your own.</p>
<h1 style="font-family: Georgia, 'Bitstream Charter', serif; color: #000000; line-height: 1.5em; font-size: 2.4em; margin-top: 0px; margin-right: 0px; margin-bottom: 20px; margin-left: 0px; font-weight: normal;">The toolbox</h1>
<ul>
<li>Windows Azure SDK</li>
<li>Windows Azure Platform Kit June 2010</li>
<li>Windows Azure Tools for Visual Studio ( v1.2 )</li>
<li>Microsoft Seadragon Ajax library</li>
<li>Microsoft SQL Server 2008 R2</li>
<li>Microsoft SQL Azure</li>
<li>ASP.NET 4 ( C# )</li>
<li>Windows Azure</li>
<li>Azure Storage Explorer</li>
</ul>
<p>Here is the <a title="The Endless Mural toolbox" href="http://automatastudios.com/the-endless-mural-toolbox/" target="_blank">toolbox that Branden used on the client side</a>.</p>
<h1>Hotlinks from the server guy</h1>
<ul>
<li><a title="Developoing and Deploying with SQL Azure" href="http://social.technet.microsoft.com/wiki/contents/articles/developing-and-deploying-with-sql-azure.aspx" target="_blank">Developing and Deploying with SQL Azure</a></li>
<li><a title="SQL Azure T-SQL reference" href="http://msdn.microsoft.com/en-us/library/ee336281.aspx" target="_blank">SQL Azure DB T-SQL reference</a></li>
<li><a title="Azure w/Intellitrace" href="http://blogs.msdn.com/b/jnak/archive/2010/06/07/using-intellitrace-to-debug-windows-azure-cloud-services.aspx" target="_blank">Azure w/Intellitrace</a></li>
<li><a title="How to upload download Page Blobs ( Windows Azure )" href="http://blogs.msdn.com/b/windowsazurestorage/archive/2010/04/11/using-windows-azure-page-blobs-and-how-to-efficiently-upload-and-download-page-blobs.aspx" target="_blank">Using Windows Azure Page Blobs .. how to upload / download blobs</a></li>
<li><a title="Azure Deep Dive : Working with configuration" href="http://azure.snagy.name/blog/?p=176" target="_blank">Windows Azure Deep Dive: Working with Configuration</a></li>
<li><a title="Getting started with Seadragon AJAX" href="http://www.seadragon.com/developer/ajax/getting-started/" target="_blank">Seadragon Ajax &#8211; Getting Started</a></li>
<li><a title="Creating Deep Zoom content" href="http://www.silverlight.net/learn/whitepapers/deep-zoom-tools/" target="_blank">Creating Content : Deep Zoom Tools</a></li>
<li><a title="Deep Zoom Blog" href="http://blogs.msdn.com/b/lutzg/" target="_blank">Deep Zoom Blog</a></li>
<li><a title="How to create a Twitter TWEET button" href="http://dev.twitter.com/pages/tweet_button" target="_blank">Twitter TWEET Button</a></li>
</ul>
<h1>It&#8217;s a wrap</h1>
<p>This project was the most concentrated five weeks I&#8217;ve had in quite some time.  I still wonder if we were only given five weeks because this was an HTML5 project.  Either way, the mural team made some magic and now you can too.  If you&#8217;re like me and just want to doodle, <a href="http://endlessmural.com/" target="_blank">go make some art at the mural</a>.  If you&#8217;re a developer interested in HTML5 and Javascript programming, go check out <a title="OKAPI.js, the javascript behind endlessmural.com" href="http://www.okapijs.org/" target="_blank">the javascript library okapi.js</a> which Branden Hall recently open sourced.</p>
<p>Also be sure to visit the magicians, I mean artists, who made the amazing patterns you see when using the mural.  I&#8217;m a life long doodler, but can&#8217;t art myself out of a paper bag.</p>
<div>
<h2 style="text-align: center;"><a title="Evgeny Kiselev" href="http://www.ekiselev.com" target="_blank">Evgeny Kiselev</a></h2>
<div id="attachment_1839" class="wp-caption aligncenter" style="width: 310px"><a href="http://ericfickes.com/wp-content/uploads/2010/11/evgeny-kiselev.jpg" rel="lightbox[1750]"><img class="size-medium wp-image-1839 " title="evgeny-kiselev" src="http://ericfickes.com/wp-content/uploads/2010/11/evgeny-kiselev-300x158.jpg" alt="Evgeny Kiselev - www.ekiselev.com" width="300" height="158" /></a><p class="wp-caption-text">Evgeny Kiselev - www.ekiselev.com</p></div>
</div>
<div>
<h2 style="text-align: center;"><a title="Guilherme Marconi" href="http://brain.marconi.nu" target="_blank">Guilherme Marconi</a></h2>
<div id="attachment_1840" class="wp-caption aligncenter" style="width: 310px"><a href="http://ericfickes.com/wp-content/uploads/2010/11/guilherme-marconi.jpg" rel="lightbox[1750]"><img class="size-medium wp-image-1840" title="guilherme-marconi" src="http://ericfickes.com/wp-content/uploads/2010/11/guilherme-marconi-300x168.jpg" alt="Guilherme Marconi - brain.marconi.nu" width="300" height="168" /></a><p class="wp-caption-text">Guilherme Marconi - brain.marconi.nu</p></div>
</div>
<div>
<h2 style="text-align: center;"><a title="Joshua Davis" href="http://www.joshuadavis.com" target="_blank">Joshua Davis</a></h2>
<div id="attachment_1841" class="wp-caption aligncenter" style="width: 310px"><a href="http://ericfickes.com/wp-content/uploads/2010/11/joshua-davis.jpg" rel="lightbox[1750]"><img class="size-medium wp-image-1841" title="joshua-davis" src="http://ericfickes.com/wp-content/uploads/2010/11/joshua-davis-300x225.jpg" alt="Joshua Davis - www.joshuadavis.com" width="300" height="225" /></a><p class="wp-caption-text">Joshua Davis - www.joshuadavis.com</p></div>
</div>
<div>
<h2 style="text-align: center;"><a title="Matt Lyon" href="http://www.c8six.com" target="_blank">Matt Lyon</a></h2>
<div id="attachment_1842" class="wp-caption aligncenter" style="width: 287px"><a href="http://ericfickes.com/wp-content/uploads/2010/11/matt-lyon.jpg" rel="lightbox[1750]"><img class="size-medium wp-image-1842" title="matt-lyon" src="http://ericfickes.com/wp-content/uploads/2010/11/matt-lyon-277x300.jpg" alt="Matt Lyon - www.c8six.com" width="277" height="300" /></a><p class="wp-caption-text">Matt Lyon - www.c8six.com</p></div>
<p>And lastly I put up a photo album on Facebook of all my camera phone pictures from the trip.  <a title="camera phone pictures from my trip to SF to launch endlessmural.com" href="http://www.facebook.com/album.php?aid=220650&amp;id=500552652&amp;l=fe921f2bc4" target="_blank">Check out the endlessmural photo album</a>.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2010/11/endless-mural-wins-fwa-site-of-the-day/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Want to see some kick ass HTML5?</title>
		<link>http://ericfickes.com/2010/09/want-to-see-some-kick-ass-html5/</link>
		<comments>http://ericfickes.com/2010/09/want-to-see-some-kick-ass-html5/#comments</comments>
		<pubDate>Thu, 16 Sep 2010 02:22:45 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[art]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[cool]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[fun]]></category>
		<category><![CDATA[Internet Explorer]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[asp.net]]></category>
		<category><![CDATA[automata studios]]></category>
		<category><![CDATA[azure]]></category>
		<category><![CDATA[beauty of the web]]></category>
		<category><![CDATA[branden hall]]></category>
		<category><![CDATA[css3]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[ie9]]></category>
		<category><![CDATA[joshua davis]]></category>
		<category><![CDATA[sql azure]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=1654</guid>
		<description><![CDATA[I&#8217;m extremely happy to announce the www.endlessmural.com project was launched today and it was a huge success.  I intend on posting something with more details when I return home, but in the meantime please please check this site out.  It&#8217;s &#8230; <a href="http://ericfickes.com/2010/09/want-to-see-some-kick-ass-html5/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m extremely happy to announce the <a href="http://www.endlessmural.com">www.endlessmural.com</a> project was launched today and it was a huge success.  I intend on posting something with more details when I return home, but in the meantime please please check this site out.  It&#8217;s my current favorite example of HTML5 in action, and it works in all modern browsers ( yes, even iPad ).</p>
<div id="attachment_1655" class="wp-caption aligncenter" style="width: 591px"><a href="http://www.endlessmural.com/"><img class="size-full wp-image-1655" title="endlessmural.com" src="http://ericfickes.com/wp-content/uploads/2010/09/endlessmural-dot-com.png" alt="The coolest HTML5 sample you will see on the internet" width="581" height="644" /></a><p class="wp-caption-text">Go make art at endlessmural.com</p></div>
<p>Endlessmural.com is a generative drawing tool written in HTML5, Javascript, CSS3, on top of a Microsoft Azure backend.  Go, make art, share the url.</p>
<p>Here is a piece I made today.</p>
<p><a href="http://www.endlessmural.com/#590"><img class="aligncenter size-medium wp-image-1656" title="You can make art at endlessmural.com" src="http://ericfickes.com/wp-content/uploads/2010/09/endlessmural-dot-com-image590-300x216.png" alt="endlessmural.com artwork" width="300" height="216" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2010/09/want-to-see-some-kick-ass-html5/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Five screencasting options for OS X</title>
		<link>http://ericfickes.com/2010/08/five-screencasting-options-for-os-x/</link>
		<comments>http://ericfickes.com/2010/08/five-screencasting-options-for-os-x/#comments</comments>
		<pubDate>Mon, 16 Aug 2010 20:33:47 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[development]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=1640</guid>
		<description><![CDATA[I recently asked for some screencasting advice and wanted to put this list up for future reference.  I ended up using Jing Free for my particular assignment, but typically use screentoaster.com since it&#8217;s free, cross platform, and web based. ScreenFlow &#8230; <a href="http://ericfickes.com/2010/08/five-screencasting-options-for-os-x/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I recently asked for some screencasting advice and wanted to put this list up for future reference.  I ended up using Jing Free for my particular assignment, but typically use screentoaster.com since it&#8217;s free, cross platform, and web based.</p>
<h2>ScreenFlow</h2>
<p>Price : $99.00</p>
<p>URL : <a title="ScreenFlow looks AMAZING!" href="http://www.telestream.net/screen-flow/" target="_blank">http://www.telestream.net/screen-flow/</a></p>
<p>Notes : ScreenFlow looks freaking amazing.  If I had to do regular screencasting, I would spend the $99 to get this application.  It appears to do, save, and export everything.  This is the best solution for any professional screencaster.</p>
<h2></h2>
<h2>Snapz Pro X</h2>
<p>Price : $69.00</p>
<p>URL : <a title="Snapz Pro X" href="http://www.ambrosiasw.com/utilities/snapzprox/" target="_blank">http://www.ambrosiasw.com/utilities/snapzprox/</a></p>
<p>Notes : If I was going to pay money for a screencast app, it would be ScreenFlow.  However, I do use <a title="Wiretap Studio let's me record ANYTHING!" href="http://www.ambrosiasw.com/utilities/wiretap/" target="_blank">Ambrosia Soft&#8217;s Wiretap Studio</a>, so I know they make great software.  If $30 is enough to affect your decision, I would highly recommend looking at this before ScreenFlow.</p>
<h2></h2>
<h2>Jing Free</h2>
<p>Price : free</p>
<p>URL : <a title="I like JING free, but pay looks good too" href="http://www.jingproject.com/features/" target="_blank">http://www.jingproject.com/features/</a></p>
<p>Notes : Jing Free is pretty sweet, but only captures a maximum of five minutes of video.  For my assignment that ended up being good so I could keep my videos short.  The pay service looks really helpful for sharing captures ( images, videos, etc ), but I just can&#8217;t justify signing up for this yet.</p>
<h2>Silverback App</h2>
<p>Price : $69.95</p>
<p>URL : <a title="Silverback looks good for usage videos and collecting feedback" href="http://silverbackapp.com/" target="_blank">http://silverbackapp.com/</a></p>
<p>Notes : This capturing app is geared towards taking videos for usability studies.  This is a really cool application that I&#8217;d take a closer look if I wasn&#8217;t such a server side programmer.  Be sure to watch the demo, it&#8217;s a really cool application, just not good for what I was doing.</p>
<h2></h2>
<h2>Screentoaster.com</h2>
<p>Price : FREE</p>
<p>URL : <a title="Free online screenrecorder" href="http://www.screentoaster.com" target="_blank">http://www.screentoaster.com</a></p>
<p>Notes : This is a free web based screen recording service that I use fairly often.  You can&#8217;t beat free, and this will run on your MAC or PC since it&#8217;s browser based.  Definitely worth a look if you need something quick and want to sharing capabilities.</p>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2010/08/five-screencasting-options-for-os-x/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Upload to ASP.NET from HTML, Flash, or Flex clients</title>
		<link>http://ericfickes.com/2010/08/upload-to-asp-net-from-html-flash-or-flex-clients/</link>
		<comments>http://ericfickes.com/2010/08/upload-to-asp-net-from-html-flash-or-flex-clients/#comments</comments>
		<pubDate>Thu, 12 Aug 2010 03:18:49 +0000</pubDate>
		<dc:creator>Eric Fickes</dc:creator>
				<category><![CDATA[.net]]></category>
		<category><![CDATA[adobe]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[coldfusion]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[flash platform]]></category>
		<category><![CDATA[FLEX]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[asp.net upload]]></category>
		<category><![CDATA[flash upload]]></category>
		<category><![CDATA[flex upload]]></category>
		<category><![CDATA[html upload]]></category>
		<category><![CDATA[NETWORK SERVICE]]></category>
		<category><![CDATA[Request.Files]]></category>
		<category><![CDATA[upload]]></category>
		<category><![CDATA[upload handler]]></category>
		<category><![CDATA[uploader]]></category>

		<guid isPermaLink="false">http://ericfickes.com/?p=1625</guid>
		<description><![CDATA[File uploading has been a hot topic during my time as an internet programmer.  In the classic ASP days this was a bit of a task to build and get correct.  Nowadays both Adobe&#8217;s Coldfusion and Microsoft&#8217;s ASP.NET both have &#8230; <a href="http://ericfickes.com/2010/08/upload-to-asp-net-from-html-flash-or-flex-clients/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>File uploading has been a hot topic during my time as an internet programmer.  In the classic ASP days this was a bit of a task to build and get correct.  Nowadays both <a title="Coldfusion makes file handling simple with &lt;CFFILE /&gt;" href="http://help.adobe.com/en_US/ColdFusion/9.0/CFMLRef/WSc3ff6d0ea77859461172e0811cbec22c24-7fa1.html" target="_blank">Adobe&#8217;s Coldfusion</a> and <a title="ASP.NET has the FileUpload class" href="http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.fileupload.aspx" target="_blank">Microsoft&#8217;s ASP.NET</a> both have built in file uploader tags ( server controls ) that handle this with ease.</p>
<p>This is great, but what happens when you have a mixed bag of clients that all need to upload to the same location?  Sometimes I work with completely ASP.NET or CF web apps, but more often than not I&#8217;m dealing with Flash clients as well as HTML clients.</p>
<p>Recently I ran into this upload scenario and built this simple ASP.NET uploader script.  This feels a bit old school since it uses .NET&#8217;s built in Request.Files collection, instead of a fancy new &#8216;all in one&#8217; server control, but I actually prefer this method.</p>
<p>Here&#8217;s all you need :</p>
<pre class="brush: csharp; title: ; notranslate">
// Check for posted files
for (int xx = 0; xx &lt; Request.Files.Count; xx++)
{
    // UPLOAD FILE
    HttpPostedFile _file = Request.Files[xx];

    // make sure we're not finding empty filename
    if (_file.FileName.Trim() != string.Empty)
    {
        // NOTE : IE &lt; 8 reports full path of file, not just filename
        // Parse out filename, then create full upload path
        var fileName = _file.FileName;
        if (fileName.Contains(&quot;\\&quot;))
        {
            var aFile = fileName.Split('\\');
            fileName = aFile[ aFile.Length - 1 ].ToString();
        }

        // create full save path for uploaded file
        var full_file_path = Server.MapPath( UP_FOLDER ) + &quot;\\&quot; + fileName;

        try
        {
            // save file to server
            _file.SaveAs(full_file_path);
        }
        catch (Exception exc)
        {
            var emsg = &quot;Unable to upload file : &quot; + exc.Message;

            Response.Write( emsg );
            Response.Flush();
            Response.End();
        }

        // show result
        Response.Write( _file.FileName + &quot; uploaded! &lt;br&gt;&quot; );
    }
}
</pre>
<p>That&#8217;s all there is to it codewise.  Before using this code you will need to give the NETWORK SERVICES user write permissions to your upload folder.  Other than that, that&#8217;s all she wrote!</p>
<p><a title="ASP.NET uploader, HTML upload, Flash upload, and Flex upload clients" href="http://ericfickes.com/code/aspxuploader.zip" target="_blank">Here is a zip of all the code for you to download</a>.</p>
<p>Inside this zip you will find :</p>
<ul>
<li><strong>flashclient.fla</strong> &#8211; Flash upload client ( <em>*be sure to update the upload path before building</em> )</li>
<li><strong>flexclient.mxml</strong> &#8211; Flex upload client ( <em>*also update upload path before building</em> )</li>
<li><strong>uploader.aspx </strong>- ASP.NET file upload handler</li>
<li><strong>uploadform.html </strong>- sample HTML upload form ( <em>again, update path</em> )</li>
</ul>
<p>Hope somebody finds this useful.</p>
]]></content:encoded>
			<wfw:commentRss>http://ericfickes.com/2010/08/upload-to-asp-net-from-html-flash-or-flex-clients/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

