<?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>Pearl Tech &#187; Application Development</title>
	<atom:link href="http://blog.pearltechnology.com/category/application-development/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.pearltechnology.com</link>
	<description></description>
	<lastBuildDate>Tue, 25 May 2010 14:37:15 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Enterprise Library Logger.Write Not Working?</title>
		<link>http://blog.pearltechnology.com/enterprise-library-logger-write-not-working/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/enterprise-library-logger-write-not-working/#comments</comments>
		<pubDate>Mon, 17 May 2010 21:29:50 +0000</pubDate>
		<dc:creator>Geer</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[Enterprise Library]]></category>
		<category><![CDATA[Logger]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=697</guid>
		<description><![CDATA[Using Logging Application Block provided by Enterprise Library is a common way of logging exceptions in .NET applications.  It&#8217;s easy to setup and to use.  One problem I had a while ago was that it worked while on my development PC, but stopped working once it&#8217;s deployed.
What I was doing was to use it to [...]]]></description>
			<content:encoded><![CDATA[<p>Using Logging Application Block provided by Enterprise Library is a common way of logging exceptions in .NET applications.  It&#8217;s easy to setup and to use.  One problem I had a while ago was that it worked while on my development PC, but stopped working once it&#8217;s deployed.</p>
<p>What I was doing was to use it to write event entries in windows event log as part of the exception handling in an ASP.NET web application.  Nothing fancy.  It worked fine on my PC, but it didn&#8217;t write anything to the event log when Logger.Write is executed. No exception was thrown from that line of code either.  The program just went through as if that line of code was skipped.</p>
<p>It turned out to be a permission issue. When I debug the application in Visual Studio, it was running under my windows account credential which had permission to create Event Source in the system.  However, when the application was deployed to the server, it was running under the default account which was &#8220;NT Authority\Network Service&#8221; in my case.  By default, that account doesn&#8217;t have permission to create new Event Source in the system.  It does have permission to write event entries though.  So, when Logger.Write was executed, it couldn&#8217;t proceed because the Event Source wasn&#8217;t there, and the program didn&#8217;t have permission to create one.  Actually, it makes sense to not throw any exception on this line, because people like me usually use this to log exceptions, and if the logging process itself throws exceptions, there is probably nowhere else we can handle and/or log them.</p>
<p>Now, how this can be resolve?  The solution is quite simple.  As long as the Event Source is created ahead of time, it will be no problem.  What I did was to create required Event Source(s) on server through CMD.exe.  Here is a sample command:</p>
<p><span style="color: #0000ff"><code>eventcreate /ID 1 /L Application /T information /SO "My Event Source" /D "My Event Source is created."</code></span></p>
<p>This command will create an event entry in the Application log.  If the Event Source doesn&#8217;t exist, it will be created during the process.  This is only required when the application is deployed to the server first time.  So, I usually do it manually on server.  However, if that&#8217;s not the case, you can build it into the installation package, and when the application is installed, the Event Source is created as well.  Of course, you can use .NET to create Event Source in your installer too.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/enterprise-library-logger-write-not-working/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Exception Handling in ASP.NET Web Application</title>
		<link>http://blog.pearltechnology.com/exception-handling-in-asp-net-web-application/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/exception-handling-in-asp-net-web-application/#comments</comments>
		<pubDate>Thu, 22 Apr 2010 22:14:09 +0000</pubDate>
		<dc:creator>Geer</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Exception Handling]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=687</guid>
		<description><![CDATA[In web application development, we should always think about returning some kind of message to users when an exception is raised in the program.  Sometimes, it can be very specific, while in other cases it can be generic.  A common thought is to capture and possibly handle exceptions where they are raised, re-throw exceptions or [...]]]></description>
			<content:encoded><![CDATA[<p>In web application development, we should always think about returning some kind of message to users when an exception is raised in the program.  Sometimes, it can be very specific, while in other cases it can be generic.  A common thought is to capture and possibly handle exceptions where they are raised, re-throw exceptions or raise custom exceptions as needed so they can propagate up to higher level tiers in the application, handle/log exceptions at a central place in the highest tier of the application, and finally display an error message to the end-users or redirect them to a customized error page.</p>
<p>This pattern works, but sometimes it is tricky to generate a meaningful message.  The problem is that the exception can be thrown anywhere in your application, and the exception message may not always be appropriate or meaningful to end-users.  If you blindly display all exception messages you finally get, users may see something like &#8220;Object reference not set to an instance of an object&#8221; which doesn&#8217;t mean much to them.  So, in the final step of exception handling (where the program displays error messages or redirect users to an error page), you will see all kinds of exceptions which include .NET originated exceptions, exceptions raised by the program on purpose, and custom exceptions.  Some of them are appropriate to show to users, while others aren&#8217;t.  So, the question is how you can distinguish among them.</p>
<p>A lot of people suggest that if the original .NET exception message isn&#8217;t meaningful to users, and you can&#8217;t provide more specific message either, then a generic message such as &#8220;An error has occurred&#8230;  Please contact the technical support team for help&#8221; can be used.  I agree too.  You may do this where you know an exception can be thrown, and re-throw the exception with customized message (whether specific or generic) and with the original exception embedded as the inner exception of the new exception.  However, you don&#8217;t want to just put try/catch blocks in every piece of your code, and catch and re-throw every exception the program may possibly encounter.  It&#8217;s labor intensive and inefficient.  Also, there will always be something you can&#8217;t think of or look over, so there are still chances you can get unexpected exceptions in the end.</p>
<p>So, my solution is to let the program only catch and re-throw .NET originated exceptions when they are predictable and additional meaningful information can be provided, and let all other exceptions bubble up to the top tier.  Then in the final step of exception handling, identify the exceptions that are re-thrown, and retrieve the error message directly from these exceptions; use a generic error message for all other exceptions.  The question is how to identify these exceptions that are re-thrown.  For this purpose, I usually create a custom exception class which is inherited from System.Exception.  Use this class whenever I need to throw new exceptions or re-throw .NET originated exceptions.  So, in the final step, I check the type of the exception, and decide whether to use it as the error message or use a generic one instead.</p>
<p>Here is the custom exception class:</p>
<div style="border: #000080 1px solid;color: #000;font-family: 'Courier New', Courier, Monospace;font-size: 10pt">
<div style="background: #ddd;overflow: auto">
<ol style="background: #ffffff;margin: 0 0 0 2.5em;padding: 0 0 0 5px">
<li><span style="color:#0000ff">public</span> <span style="color:#0000ff">class</span> <span style="color:#2b91af">ExceptionBase</span> : <span style="color:#2b91af">Exception</span></li>
<li>{</li>
<li><span style="color:#0000ff">public</span> ExceptionBase(<span style="color:#0000ff">string</span> msg, <span style="color:#2b91af">Exception</span> innerEx)</li>
<li>: <span style="color:#0000ff">base</span>(msg, innerEx)</li>
<li>{</li>
<li>}</li>
<li><span style="color:#0000ff">public</span> ExceptionBase(<span style="color:#0000ff">string</span> msg)</li>
<li>: <span style="color:#0000ff">base</span>(msg)</li>
<li>{</li>
<li>}</li>
<li>}</li>
</ol>
</div>
</div>
<p>The ExceptionBase class has two constructors which give you the options to create an instance of exception with customized error message and with/without inner exception.</p>
<p>Here is how to use it in code:</p>
<div style="border: #000080 1px solid;color: #000;font-family: 'Courier New', Courier, Monospace;font-size: 10pt">
<div style="background: #ddd;overflow: auto">
<ol style="background: #ffffff;margin: 0 0 0 2em;padding: 0 0 0 5px">
<li><span style="color:#0000ff">throw</span> <span style="color:#0000ff">new</span> <span style="color:#2b91af">ExceptionBase</span>(<span style="color:#a31515">&#8220;Error has occurred in accessing database.&#8221;</span>);</li>
</ol>
</div>
</div>
<p>Or</p>
<div style="border: #000080 1px solid;color: #000;font-family: 'Courier New', Courier, Monospace;font-size: 10pt">
<div style="background: #ddd;overflow: auto">
<ol style="background: #ffffff;margin: 0 0 0 2em;padding: 0 0 0 5px">
<li><span style="color:#0000ff">try</span></li>
<li>{</li>
<li><span style="color:#008000">// Data access operations</span></li>
<li>}</li>
<li><span style="color:#0000ff">catch</span> (<span style="color:#2b91af">Exception</span> ex)</li>
<li>{</li>
<li><span style="color:#0000ff">throw</span> <span style="color:#0000ff">new</span> <span style="color:#2b91af">ExceptionBase</span>(<span style="color:#a31515">&#8220;Error has occurred in accessing database.&#8221;</span>, ex);</li>
<li>}</li>
</ol>
</div>
</div>
<p>The central location I handle all exceptions is in global.asax, and here is what it looks like:</p>
<div style="border: #000080 1px solid;color: #000;font-family: 'Courier New', Courier, Monospace;font-size: 10pt">
<div style="background: #ddd;overflow: auto">
<ol style="background: #ffffff;margin: 0 0 0 2.5em;padding: 0 0 0 5px">
<li><span style="color:#0000ff">protected</span> <span style="color:#0000ff">void</span> Application_Error(<span style="color:#0000ff">object</span> sender, <span style="color:#2b91af">EventArgs</span> e)</li>
<li>{</li>
<li><span style="color:#2b91af">Exception</span> ex = Server.GetLastError();</li>
<li><span style="color:#0000ff">string</span> msg = <span style="color:#a31515">&#8220;Unexpected error has occurred.&#8221;</span>;</li>
<li><span style="color:#0000ff">if</span> (ex != <span style="color:#0000ff">null</span>)</li>
<li>{</li>
<li><span style="color:#2b91af">LoggingUtility</span>.LogException(ex);</li>
<li><span style="color:#008000">// Remove the HttpUnhandledException wrapper if there is one</span></li>
<li><span style="color:#0000ff">if</span> (ex.GetType() == <span style="color:#0000ff">typeof</span>(<span style="color:#2b91af">HttpUnhandledException</span>) &amp;&amp; ex.InnerException != <span style="color:#0000ff">null</span>)</li>
<li>{</li>
<li>ex = ex.InnerException;</li>
<li>}</li>
<li><span style="color:#008000">// If this is a custom exception, change the message.</span></li>
<li><span style="color:#0000ff">if</span> (ex <span style="color:#0000ff">is</span> <span style="color:#2b91af">ExceptionBase</span>)</li>
<li>msg = ex.Message;</li>
<li>Server.ClearError();</li>
<li>}</li>
<li><span style="color:#008000">// Try to redirect user.</span></li>
<li>Response.Redirect(<span style="color:#0000ff">string</span>.Format(<span style="color:#a31515">&#8220;~/Error.htm?aspxerrorpath={0}&amp;error={1}&#8221;</span>, <span style="color:#2b91af">HttpUtility</span>.UrlEncodeUnicode(Request.Url.PathAndQuery), msg), <span style="color:#0000ff">true</span>);</li>
<li>}</li>
</ol>
</div>
</div>
<p>One note for this is that ASP.NET may put a wrapper exception (HttpUnhandledException) around the original exception.  In the code above, it is simply removed because it doesn&#8217;t contain any useful information.</p>
<p>You can also create more custom exception classes based on the ExceptionBase class to improve consistency in your application, and the code above will still work.  One example is:</p>
<div style="border: #000080 1px solid;color: #000;font-family: 'Courier New', Courier, Monospace;font-size: 10pt">
<div style="background: #ddd;overflow: auto">
<ol style="background: #ffffff;margin: 0 0 0 2em;padding: 0 0 0 5px">
<li><span style="color:#0000ff">public</span> <span style="color:#0000ff">class</span> <span style="color:#2b91af">BadUrlException</span> : <span style="color:#2b91af">ExceptionBase</span></li>
<li>{</li>
<li><span style="color:#0000ff">public</span> BadUrlException(<span style="color:#2b91af">Exception</span> innerEx)</li>
<li>: <span style="color:#0000ff">base</span>(<span style="color:#a31515">&#8220;Bad URL has been detected. Request could not be processed.&#8221;</span>, innerEx)</li>
<li>{</li>
<li>}</li>
<li>}</li>
</ol>
</div>
</div>
<p>This way the error messages for one type of exception are consistent across the application.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/exception-handling-in-asp-net-web-application/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to Use Microsoft Device Emulator in VS2008</title>
		<link>http://blog.pearltechnology.com/how-to-use-microsoft-device-emulator-in-vs2008/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/how-to-use-microsoft-device-emulator-in-vs2008/#comments</comments>
		<pubDate>Wed, 31 Mar 2010 13:37:18 +0000</pubDate>
		<dc:creator>Geer</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Device Emulator]]></category>
		<category><![CDATA[mobile]]></category>
		<category><![CDATA[visual studio 2008]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=658</guid>
		<description><![CDATA[Microsoft Device Emulator is a great tool for testing your mobile web applications without utilizing any real mobile device.  Because it can use the same network that your computer is on, you can use it to test your mobile web applications hosted on development computers or test servers before the applications are published to the internet.  [...]]]></description>
			<content:encoded><![CDATA[<p>Microsoft Device Emulator is a great tool for testing your mobile web applications without utilizing any real mobile device.  Because it can use the same network that your computer is on, you can use it to test your mobile web applications hosted on development computers or test servers before the applications are published to the internet.  It is part of the Visual Studio 2008, so you can set it up with very minimal work, if you already have VS2008 installed.  It can also be installed separately.  In the rest of this post, I will demonstrate how to set it up, to use your local network and access your mobile web applications.</p>
<p>Here are a few things you will need to have on your computer to continue.</p>
<ol>
<li>Windows Virtual PC 2007.  This is required, if you would like to connect the Device Emulator to your local network.  The software can be downloaded from <a title="Download Virutal PC 2007" href="http://www.microsoft.com/windows/virtual-pc/download.aspx" target="_blank">Microsoft website</a>.</li>
<li>Microsoft Visual Studio 2008.</li>
<li>Microsoft Device Emulator (which comes with VS2008).</li>
</ol>
<p>With all the above requirements available on your computer, you can follow the steps below to configure your Device Emulator.</p>
<ol>
<li>Start VS 2008 IDE.</li>
<li>On the menu, go to Tools &gt;&gt; Device Emulator Manager
<div id="attachment_659" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-659" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/IDE1-300x233.jpg" alt="Start Device Emulator Manager" width="300" height="233" /><p class="wp-caption-text">Start Device Emulator Manager</p></div></li>
<li>Right-click on a device you would like to use, and choose Connect option.
<p><div id="attachment_660" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-660" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Connect-to-a-mobile-device-300x222.jpg" alt="Connect to A Mobile Device" width="300" height="222" /><p class="wp-caption-text">Connect to A Mobile Device</p></div></li>
<li>After the device is connected, right-click on the connected device again, and choose Cradle.
<p><div id="attachment_661" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-661" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Cradle-Device-300x214.jpg" alt="Cradle the Connected Device" width="300" height="214" /><p class="wp-caption-text">Cradle the Connected Device</p></div></li>
<li>Go to the device window.  On the menu, choose File &gt;&gt; Configure
<p><div id="attachment_662" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-662" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Configure-Device-300x209.jpg" alt="Configure Device" width="300" height="209" /><p class="wp-caption-text">Configure Device</p></div></li>
<li>Go to the Network tab, and select the options as shown in the screen shot below.  And then click OK to close the window.
<p><div id="attachment_663" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-663" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Choose-Network-Card-300x223.jpg" alt="Choose Network Card" width="300" height="223" /><p class="wp-caption-text">Choose Network Card</p></div></li>
<li>In the device window, on the menu, choose File &gt;&gt; Reset &gt;&gt; Soft.  And wait until the device is restarted.</li>
<li>Now you need to configure the internet connection in the mobile device.  (The process could be different depending on what device you have picked.)  Normally, you would find the Settings option in the main menu, and then go to the Connections section to choose/define an internet connection.  Here below I use the device I chose as an example.</li>
<li>Choose Settings &gt;&gt; Connections &gt;&gt; Advanced &gt;&gt; Select Networks, and then choose My ISP for both Internet and Private Network connections.
<p><div id="attachment_668" class="wp-caption alignnone" style="width: 190px"><img class="size-medium wp-image-668" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Settings-180x300.jpg" alt="Choose Settings" width="180" height="300" /><p class="wp-caption-text">Choose Settings</p></div>
<div id="attachment_667" class="wp-caption alignnone" style="width: 189px"><img class="size-medium wp-image-667" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Connections-179x300.jpg" alt="Choose Connections" width="179" height="300" /><p class="wp-caption-text">Choose Connections</p></div>
<div id="attachment_665" class="wp-caption alignnone" style="width: 190px"><img class="size-medium wp-image-665" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Advanced-Settings-180x300.jpg" alt="Choose Advanced Settings" width="180" height="300" /><p class="wp-caption-text">Choose Advanced Settings</p></div>
<p><div id="attachment_666" class="wp-caption alignnone" style="width: 190px"><img class="size-medium wp-image-666" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Choose-My-ISP-180x300.jpg" alt="Choose My ISP" width="180" height="300" /><p class="wp-caption-text">Choose My ISP</p></div></li>
<li>After confirming all these changes, you can now visit your mobile web application or internet using this Device Emulator.  Task accomplished!
<p><div id="attachment_669" class="wp-caption alignnone" style="width: 190px"><img class="size-medium wp-image-669" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Mobile-Website-180x300.jpg" alt="Your Mobile Website" width="180" height="300" /><p class="wp-caption-text">Your Mobile Website</p></div></li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/how-to-use-microsoft-device-emulator-in-vs2008/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting Siebel EIM Process Batch Number in Command Line</title>
		<link>http://blog.pearltechnology.com/setting-siebel-eim-process-batch-number-in-command-line/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/setting-siebel-eim-process-batch-number-in-command-line/#comments</comments>
		<pubDate>Thu, 25 Mar 2010 15:02:19 +0000</pubDate>
		<dc:creator>Geer</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Miscellaneous]]></category>
		<category><![CDATA[BATCH]]></category>
		<category><![CDATA[Command]]></category>
		<category><![CDATA[EIM]]></category>
		<category><![CDATA[Siebel]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=628</guid>
		<description><![CDATA[My customer&#8217;s current process of importing data into Siebel database is to use Siebel EIM interface.  The data which needs to be imported will be formatted and inserted into EIM tables (or the staging tables), and then an EIM process will be ticked off in the command line to import the data into Siebel base [...]]]></description>
			<content:encoded><![CDATA[<p>My customer&#8217;s current process of importing data into Siebel database is to use Siebel EIM interface.  The data which needs to be imported will be formatted and inserted into EIM tables (or the staging tables), and then an EIM process will be ticked off in the command line to import the data into Siebel base tables.  The command is fairly simple, and should be similar to the following:</p>
<p><span style="color: #0000ff;font-family: Courier New">[Path to The Siebel Application Bin folder]\srvrmgr.exe /g [Siebel Application Server Name] /e [Target Siebel Environment] /s [Siebel Application Server Name] /u [User Name] /p [User Password]</span></p>
<p><span style="color: #0000ff;font-family: Courier New"><br />
run task for component EIM with config=&#8221;[Config File].ifb&#8221;,Process=&#8221;[Process Name]&#8220;</span></p>
<p>The first command starts the srvrmgr program, and the second one ticks off the EIM process.  The configuration file ([config File].ifb) specifies all the parameters needed by the EIM interface in order to complete the process.  One of the important parameters we need to set in the .ifb file is the BATCH, which is the identifier for the group of data being handled during the current process.  Normally, we set it to a fixed number or a range of numbers (for example, 500-600).  So, when the EIM process runs, only the data with a batch number equal to the BATCH or falling in the range specified in the .ifb file will be processed.  If in the EIM tables there are some records which are not ready to be processed at this moment, they can be skipped by identifying themselves with a different batch number.  This is helpful when you are managing multiple data importing tasks which share the same set of EIM tables, and run at different time.</p>
<p>However, we soon realized that it would be getting harder and harder to manage these .ifb files and to make sure these EIM processes don&#8217;t interfere with each other.  For example, one of our custom applications needs to import data into Siebel using EIM interface upon users&#8217; requests.  The data importing process is exactly the same for all these requests, except for the data needed to be imported.  Multiple users need to be allowed to submit their requests at the same time, and their requests should be handled separately.  If we were going to do it in the old fashion, we would need to have a .ifb file for each of their requests, and use different batch numbers in these .ifb files.  It is not realistic, or it is something we want to do either.</p>
<p>The solution is actually very simple.  We took the BATCH setting out of the .ifb file, and instead we set it in the command line.  This was not documented in the Siebel EIM Admin Guide, but after our testing it was proved to be a working solution.  The command will look like the following now:</p>
<p><span style="color: #0000ff;font-family: Courier New">[Siebel Application Bin folder]\srvrmgr.exe /g [Siebel Application Server Name] /e [Target Siebel Environment] /s [Siebel Application Server Name] /u [User Name] /p [User Password]</span></p>
<p><span style="color: #0000ff;font-family: Courier New"><br />
run task for component EIM with config=&#8221;[Config File].ifb&#8221;,Process=&#8221;[Process Name]&#8220;<span style="color: #ff0000">,BATCH=[Batch Number]</span></span></p>
<p>This way the application can choose a BATCH number unique to the user&#8217;s request, construct the command, and then execute it to tick off the EIM process, and all these requests can share the same .ifb file.</p>
<p>To manage the batch numbers among different applications, we reserved a range of batch numbers for each application.  For example, from 500 to 549 will be used only by application A, and from 550 to 599 will be used only by application B.  Within each application, a batch number is assigned to each request based on the request identifier and the range of batch numbers reserved for the application.  In our case, the request ID is an auto-incrementing integer, and the equation for calculating the batch number is:</p>
<p><span style="color: #0000ff;font-family: Courier New">[Batch Number] = [Request ID] % [Total Number of Allocated Batch Numbers] + [The Lowest Batch Number]<br />
(Where % stands for the modulus operator)</span></p>
<p>For example, if the allocated batch numbers are from 500 to 549, and the current request ID is 1034, the batch number for this request will then be:</p>
<p><span style="color: #0000ff;font-family: Courier New">534 = 1034 % (549 &#8211; 500 + 1) + 500</span></p>
<p>This way the adjacent requests would have different batch numbers, and the batch numbers are used in a cycle.  In our case, we will never have more than 50 users submitting their requests at the same time, but if this was for a larger user base, we could allocated a bigger range of batch numbers.</p>
<p>So, we finally were able to manage all users&#8217; requests using limited batch numbers and a single .ifb file without the requests being interfered by each other.  Task accomplished!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/setting-siebel-eim-process-batch-number-in-command-line/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Developing with Windows Mobile 7</title>
		<link>http://blog.pearltechnology.com/developing-with-windows-mobile-7/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/developing-with-windows-mobile-7/#comments</comments>
		<pubDate>Wed, 24 Mar 2010 21:27:28 +0000</pubDate>
		<dc:creator>AaronH</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Silverlight]]></category>
		<category><![CDATA[Windows Mobile Phone]]></category>
		<category><![CDATA[Windows Phone Application]]></category>
		<category><![CDATA[WPF]]></category>
		<category><![CDATA[XAML]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=618</guid>
		<description><![CDATA[Microsoft recently announced the general availability of developer tools for their Windows mobile platform. This article is a brief introduction to the platform and what the next generation of mobile development for Microsoft looks like.
After you&#8217;ve downloaded the developer tools installer, you will go through a download process&#8230;



After downloading the remaining components, you will install [...]]]></description>
			<content:encoded><![CDATA[<p>Microsoft recently announced the general availability of <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=2338b5d1-79d8-46af-b828-380b0f854203&amp;displaylang=en">developer tools</a> for their <a href="http://www.microsoft.com/windowsmobile/en-us/default.mspx">Windows mobile platform</a>. This article is a brief introduction to the platform and what the next generation of mobile development for Microsoft looks like.</p>
<p>After you&#8217;ve downloaded the <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=2338b5d1-79d8-46af-b828-380b0f854203&amp;displaylang=en">developer tools</a> installer, you will go through a download process&#8230;</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Dev-Tools-Setup.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-619" title="WinMo Dev Tools Setup" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Dev-Tools-Setup-300x267.png" alt="WinMo Dev Tools Setup" width="300" height="267" /></a><br />
</center></p>
<p>After downloading the remaining components, you will install all component resources.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Dev-Tools-Install.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-621" title="WinMo Dev Tools Install" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Dev-Tools-Install-300x271.png" alt="WinMo Dev Tools Install" width="300" height="271" /></a><br />
</center></p>
<p>Once the developer tools have been installed, you can startup <strong>Visual Studio 2010 Express for Windows Phone</strong> which is the IDE used for the mobile development.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Visual-Studio-2010-Express-Splash.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-622" title="Visual Studio 2010 Express Splash" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Visual-Studio-2010-Express-Splash-300x208.png" alt="Visual Studio 2010 Express Splash" width="300" height="208" /></a><br />
</center></p>
<p>We will use the <em>Silverlight for Windows Phone &#8211; Windows Phone Application</em> project template and add some custom XAML and image resource to the base project.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Project-Creation.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-623" title="WinMo Project Creation" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Project-Creation-300x205.png" alt="WinMo Project Creation" width="300" height="205" /></a><br />
</center></p>
<p>In this simple application we&#8217;ve titled <strong>Mobile Portal</strong> just going to add some textblocks, buttons, and use a standard Silverlight grid layout. We first modify <strong>MainPage.xaml</strong> to create our custom view for the mobile application. Here is a view of our coding changes.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-MainPage-XAML.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-630" title="WinMo MainPage XAML" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-MainPage-XAML-300x125.png" alt="WinMo MainPage XAML" width="300" height="125" /></a><br />
</center></p>
<p>Next, we go to our Solution Explorer add our image resource using the context menu on the project and selecting <em>Add -&gt; Existing Item</em>.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Solution-Explorer-Add-Resources.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-631" title="Solution Explorer - Add Resources" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/Solution-Explorer-Add-Resources-223x300.png" alt="Solution Explorer - Add Resources" width="223" height="300" /></a><br />
</center></p>
<p>Finally, we add our custom styles to <strong>App.xaml</strong>. After building the solution and running the emulator, we see the following results.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Pearl-Technology-Issue-Tracker.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-633" title="WinMo Pearl Technology - Issue Tracker" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Pearl-Technology-Issue-Tracker-151x300.png" alt="WinMo Pearl Technology - Issue Tracker" width="151" height="300" /></a><br />
</center></p>
<p>If we rotate the device orientation, we can see how the view shifts to fit the space available.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Pearl-Technology-Issue-Tracker-Horizontal.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-634" title="WinMo Pearl Technology - Issue Tracker - Horizontal" src="http://blog.pearltechnology.com/wp-content/uploads/2010/03/WinMo-Pearl-Technology-Issue-Tracker-Horizontal-300x177.png" alt="WinMo Pearl Technology - Issue Tracker - Horizontal" width="300" height="177" /></a><br />
</center></p>
<p>We are glad to see that Microsoft is embracing the <a href="http://windowsclient.net/wpf/">WPF</a> and <a href="http://www.silverlight.net/">Silverlight</a>-based development engine for the mobile platform. This decision allows developers and designers skilled in <a href="http://msdn.microsoft.com/en-us/library/ms752059.aspx">XAML</a> to leverage their existing knowledge and prowess to create useful mobile applications for both business and pleasure. The small footprint of Silverlight makes it ideal for usage with embedded or mobile systems with limited power and memory.</p>
<p>You can download our complete solution <a href="/wp-content/uploads/2010/03/PearlTechnology.IssueTracker.zip#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/developing-with-windows-mobile-7/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>FileUpload Control not working in UpdatePanel</title>
		<link>http://blog.pearltechnology.com/fileupload-control-not-working-in-updatepanel/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/fileupload-control-not-working-in-updatepanel/#comments</comments>
		<pubDate>Mon, 25 Jan 2010 16:08:11 +0000</pubDate>
		<dc:creator>Geer</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[FileUpload]]></category>
		<category><![CDATA[UpdatePanel]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=606</guid>
		<description><![CDATA[You may have experienced the problem with FileUpload control in an UpdatePanel – when you hit the submit button, Request.Files.Count always returns 0, even though you had registered the submit button as a PostBackControl and a PostBackTrigger of the UpdatePanel containing the FileUpload control.
In my case, the FileUpload only works when it is visible when [...]]]></description>
			<content:encoded><![CDATA[<p>You may have experienced the problem with FileUpload control in an UpdatePanel – when you hit the submit button, Request.Files.Count always returns 0, even though you had registered the submit button as a PostBackControl and a PostBackTrigger of the UpdatePanel containing the FileUpload control.</p>
<p>In my case, the FileUpload only works when it is visible when the page is first time loaded (not a postback).  It will not work (Request.Files.Count returns 0) when it is hidden originally and then made visible during later AsyncPostBacks.  Maybe ASP.NET is confused, because I am also changing the submit button’s postback type between full postback and aysnc postback.  The submit button is used by other things, and I only want it to fire a full post back when files need to be uploaded, and in all other cases, I want it to fire async postback and only do partial update on my page.</p>
<p>I spent many hours trying many different solutions I saw on the internet, but none of them worked for me.  However, I found an important hint which led me to the final working solution.  That is the Enctype attribute of the Form.  I learned that the Form.Enctype has to be “multipart/form-data” when files need to be uploaded.  I think this is set automatically for you in normal cases, but it isn’t set up correctly in my case.  So, I manually set it to “multipart/form-data” in OnInit of my user control, and it solves the problem.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/fileupload-control-not-working-in-updatepanel/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adding PDF icon to SharePoint Document Libraries</title>
		<link>http://blog.pearltechnology.com/adding-pdf-icon-to-sharepoint-document-libraries/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/adding-pdf-icon-to-sharepoint-document-libraries/#comments</comments>
		<pubDate>Mon, 16 Nov 2009 17:10:16 +0000</pubDate>
		<dc:creator>AaronH</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Document Libraries]]></category>
		<category><![CDATA[MOSS 2007]]></category>
		<category><![CDATA[PDF]]></category>
		<category><![CDATA[PDF Icon]]></category>
		<category><![CDATA[Sharepoint]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=574</guid>
		<description><![CDATA[One of the missing features in MOSS 2007 is the ability to recognize PDF files in a document library. It can be frustrating when all you see is a blank page icon instead of SharePoint recognizing the document type properly. This is a common portal issue that is easily remedied with a bit of extra [...]]]></description>
			<content:encoded><![CDATA[<p>One of the missing features in MOSS 2007 is the ability to recognize PDF files in a document library. It can be frustrating when all you see is a blank page icon instead of SharePoint recognizing the document type properly. This is a common portal issue that is easily remedied with a bit of <a href="http://support.microsoft.com/kb/837849">extra configuration</a>. Here is an example of how PDF items are normally displayed inside of a library view.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Missing-Icon-Example.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-577" title="Missing Icon Example" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Missing-Icon-Example-300x80.png" alt="Missing Icon Example" width="300" height="80" /></a><br />
</center></p>
<p>Following the <a href="http://support.microsoft.com/kb/837849">Microsoft KB</a> you can see that you need to edit the <em>docicon.xml</em> file located at the path <em>C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\XML</em></p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Docicon-XML.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-582" title="Docicon XML" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Docicon-XML-300x147.png" alt="Docicon XML" width="300" height="147" /></a><br />
</center></p>
<p>The Docicon.xml configuration file is a listing of all document types that are supported by SharePoint. To support the PDF icon, you need to add the following Mapping XML element to the XPath <em>//DocIcons/ByExtension</em>. The Mappings are listed in alphabetical order, so you should insert the PDF mapping accordingly.</p>
<pre name="code" language="XML">&lt;Mapping Key="pdf" Value="pdficon.gif"/&gt;</pre>
<p>Here is the Docicon.xml file after the edit.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Docicon-XML-View.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-583" title="Docicon XML View" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Docicon-XML-View-300x72.png" alt="Docicon XML View" width="300" height="72" /></a><br />
</center></p>
<p><a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/pdficon.gif#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="alignleft size-full wp-image-590" style="padding-right: 10px" title="pdficon" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/pdficon.gif" alt="pdficon" width="17" height="17" /></a>The next step is retrieving the <a href="http://www.adobe.com/misc/linking.html#pdficon">small PDF icon</a> from Adobe. When you have download the icon image, you need to save the image as &#8220;pdficon.gif&#8221; to match the mappings entry we created earlier. The last step is to copy the PDF icon image to the SharePoint template images path: <em>C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\IMAGES\pdficon.gif</em>. This is the location where SharePoint will search for document type icons for rendering in document library views &#8211; according to the configured file extension mappings in docicon.xml.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/pdficon-View.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-593" title="pdficon View" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/pdficon-View-300x146.png" alt="pdficon View" width="300" height="146" /></a><br />
</center></p>
<p>After these steps have been completed, you can now visually distinguish the document type for PDF extensions with a quick icon type indicator.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/PDF-Icon-Appears.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-596" title="PDF Icon Appears" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/PDF-Icon-Appears-300x70.png" alt="PDF Icon Appears" width="300" height="70" /></a><br />
</center></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/adding-pdf-icon-to-sharepoint-document-libraries/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Easy Access to Code Snippets with CodeKeep</title>
		<link>http://blog.pearltechnology.com/easy-access-to-code-snippets-with-codekeep/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/easy-access-to-code-snippets-with-codekeep/#comments</comments>
		<pubDate>Mon, 09 Nov 2009 19:37:34 +0000</pubDate>
		<dc:creator>ThadK</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Microsoft]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=554</guid>
		<description><![CDATA[Code Keep is an easy way to manage and browse code snippets.]]></description>
			<content:encoded><![CDATA[<p>Remembering exact syntax seems to be a common issue for programmers.  We tend to rely on Google or previous projects for a quick example to get us on the right path.  Whether it’s a one line regular expression or an entire method, programmers are frequently looking at code samples.</p>
<p>Visual Studio has built in support for snippets, but some of the functionality is limited.  For a while, I have kept simple methods and queries stored in files on my computer for quick access.  I have found a simple solution for Visual Studio, as well as online for quickly accessing, storing and sharing routinely used snippets of code that will replace my old ways of storing snippets.</p>
<p>&lt;code:keep&gt; (<a href="http://www.codekeep.net/" target="_blank">www.CodeKeep.net</a>) allows users to store and easily retrieve code snippets in many common programming languages.  At the time of this posting, there are currently 28 languages that you can store, share, and search.  There are two easy ways of adding and viewing your snippets.  First, is on their website.  The website allows you to not only view and manager your snippets, but it also lets you look through snippets other have chosen to share &#8211; when adding snippets, you have the ability to make your snippets private or public.  The other way to access snippets is through a Visual Studio add-in (available in for both Visual Studio 2005 and 2008).  Both options will let you store, browse, and search for code snippets.</p>
<p><strong>Installation instructions</strong></p>
<p>When installing, I recommend setting up an online account first.  This will make the installation flow a little more smoothly.  <em>Make sure to have Visual Studio closed for the installation.</em> Once you have an account setup, download and run the MSI to install CodeKeep.  Make sure the read the ReadMe file.  After installing the application, you will also need to copy three files into the Addins directory in you default project folder.</p>
<p>Once installed, the add-in is available through the Tools Menu<br />
<img src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/codekeep_tools.jpg" alt="Code Keep Tools Menu" /><br />
Because this is an online service, the snippets are not stored on your computer by default.   However, the website does allow users to export their snippets.  Whether you want to take them on the go, or simply back them up, browse to “My Snippets” and click Export Snippets.  All of your snippets can be saved to an XML file.<br />
<img src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/codekeep_export.jpg" alt="Code Keep Export" /><br />
<em><br />
Note:  While using the add-in, I have hit a few bugs that will crash Visual Studio.   Upon restarting VS, I get an error “Object reference not set to an instance of an object”.  To get rid of this, I had run the MSI again and  repair the installation. </em><br />
<img src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/codekeep_error.jpg" alt="Code Keep Error" /><br />
<em>This also required me to log into my account again.</em></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/easy-access-to-code-snippets-with-codekeep/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Deploying to Google App Engine</title>
		<link>http://blog.pearltechnology.com/deploying-to-google-app-engine/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/deploying-to-google-app-engine/#comments</comments>
		<pubDate>Thu, 05 Nov 2009 17:55:40 +0000</pubDate>
		<dc:creator>AaronH</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[App Engine]]></category>
		<category><![CDATA[cloud]]></category>
		<category><![CDATA[Cloud Computing]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Google App Engine]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=456</guid>
		<description><![CDATA[
Google has opened up their hosting services to the cloud with their free Google App Engine offering. Google makes it quick and easy to get going with their cloud offerings. Here a quick review of how to get started with the App Engine.
To use App Engine, you need a Google Account. Once you have your [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/appengine.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="alignleft size-full wp-image-458" title="Google App Engine" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/appengine.png" alt="Google App Engine" width="145" height="111" /></a><br />
Google has opened up their hosting services to the cloud with their free <a href="http://appengine.google.com">Google App Engine</a> offering. Google makes it quick and easy to get going with their cloud offerings. Here a quick review of how to get started with the App Engine.</p>
<p>To use App Engine, you need a <a href="https://www.google.com/accounts/NewAccount">Google Account</a>. Once you have your Google Account, you can enable App Engine services by entering in your cell phone number and carrier on the App Engine <a href="https://appengine.google.com">setup page</a>. Google will send you an SMS with an access code you need to enter into the website. This activation scheme is Google&#8217;s way of restricting you from creating multiple App Engine accounts.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Google-Apps-Verify.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-465" title="Google Apps Verify" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Google-Apps-Verify-300x141.png" alt="Google Apps Verify" width="300" height="141" /></a><br />
</center></p>
<p>When you have received your code via SMS and entered your activation code, you can begin creating applications. The following appears after you have activated your App Engine account.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Create-Google-App.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-469" title="Create Google App" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Create-Google-App-300x78.png" alt="Create Google App" width="300" height="78" /></a><br />
</center></p>
<p>When you click &#8220;Create an Application&#8221; you can enter an application alias where your new application will be hosted on the appspot.com domain.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Create-Google-App-2.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-472" title="Create Google App Alias" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Create-Google-App-2-300x96.png" alt="Create Google App Alias" width="300" height="96" /></a><br />
</center></p>
<p>If your alias is available, you can then create an application and deploy to your new cloud application. In this example, we created the alias &#8220;pearlcompanies&#8221;.</p>
<p>Since we&#8217;re running in a windows environment, our next step is to setup <a href="http://www.eclipse.org/downloads/">Eclipse</a> and the <a href="http://code.google.com/appengine/docs/java/tools/eclipse.html">Google Plugin for Eclipse</a> to deploy to our cloud application. We used Eclipse 3.5 (Galileo) in our example. After unpacking the Eclipse folder contents, we tell Eclipse where to get the Google Plugin. We add the available software site &#8220;http://dl.google.com/eclipse/plugin/3.5&#8243; to our Eclipse Preferences.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Available-Software-Sites.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-477" title="Available Software Sites" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Available-Software-Sites-300x191.png" alt="Available Software Sites" width="300" height="191" /></a><br />
</center></p>
<p>Download and Install both the Google Eclipse plugin and GWT and App Engine SDKs.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Install-Google-Plugin.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-478" title="Install Google Plugin" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Install-Google-Plugin-300x299.png" alt="Install Google Plugin" width="300" height="299" /></a><br />
</center></p>
<p>After installing the Google SDKs, we can create Google App Engine projects (Web Application Projects). The nice thing here is that we can run the cloud application locally and verify it before deploying remotely to the cloud. The Google SDK comes with the components necessary to simulate the cloud environment.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Create-Google-Web-Project.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-484" title="Create Google Web Project" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Create-Google-Web-Project-262x300.png" alt="Create Google Web Project" width="262" height="300" /></a><br />
</center></p>
<p>Once we have our web project, we can begin creating our WAR package for deployment into the App Engine cloud service. The current App Engine supports Java and Python environments, but in this example we are going to use the Java runtime. Since we&#8217;re demonstrating deployment here, we are not going to use any servlets, but simply an HTML front-end. After changing the index.html page in our web project, we click the App Engine icon in the Eclipse toolbar.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/App-Engine-Deploy-Icon.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-full wp-image-485" title="App Engine Deploy Icon" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/App-Engine-Deploy-Icon.png" alt="App Engine Deploy Icon" width="225" height="31" /></a><br />
</center></p>
<p>After clicking the icon, we are prompted with the deployment wizard which has our Google account credentials and a link to the App Engine project settings. Click the project settings and enter the Application ID and version for the application (<em>use the alias we setup previously</em>).</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/App-Engine-Properties.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-488" title="App Engine Properties" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/App-Engine-Properties-300x263.png" alt="App Engine Properties" width="300" height="263" /></a><br />
</center></p>
<p>Click &#8216;Ok&#8217; on the properties dialog, and then enter your login credentials. Once you click &#8216;Deploy&#8217;, your application will be pushed into the Google App Engine cloud. You can view and manage your applications that are live in the Google App Engine site.</p>
<p><center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Google-Apps-List.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-489" title="Google Apps List" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Google-Apps-List-300x112.png" alt="Google Apps List" width="300" height="112" /></a><br />
</center></p>
<p>You can view the clone of our Pearl Companies website which we deployed to <a href="http://pearlcompanies.appspot.com">pearlcompanies.appspot.com</a>. Please let us know about your App Engine experiences. We look forward to using this new powerful platform.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/deploying-to-google-app-engine/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Deploying to Windows Azure</title>
		<link>http://blog.pearltechnology.com/deploying-to-windows-azure/#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed</link>
		<comments>http://blog.pearltechnology.com/deploying-to-windows-azure/#comments</comments>
		<pubDate>Mon, 02 Nov 2009 20:32:25 +0000</pubDate>
		<dc:creator>AaronH</dc:creator>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Azure Services]]></category>
		<category><![CDATA[Azure Tools]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[Web Role]]></category>
		<category><![CDATA[Windows Azure]]></category>

		<guid isPermaLink="false">http://blog.pearltechnology.com/?p=504</guid>
		<description><![CDATA[Microsoft is expected to remove the CTP from their Azure Platform this month at PDC in Los Angeles. Until then, you can still receive access to their free cloud services platform. To get started with Azure you need a Windows Live ID and signup with Microsoft Connect to receive an access code (aka tokens).



When you [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Windows-Azure.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="alignleft size-medium wp-image-508" title="Windows Azure" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Windows-Azure-300x54.png" alt="Windows Azure" width="300" height="54" /></a>Microsoft is expected to remove the CTP from their <a href="http://www.microsoft.com/windowsazure/">Azure Platform</a> this month at <a href="http://microsoftpdc.com/">PDC</a> in Los Angeles. Until then, you can still receive access to their free cloud services platform. To get started with Azure you need a Windows Live ID and <a href="http://www.microsoft.com/windowsazure/account/">signup</a> with <a href="http://connect.microsoft.com/">Microsoft Connect</a> to receive an access code (<em>aka tokens</em>).<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Microsoft-Connect.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="size-medium wp-image-511" title="Microsoft Connect" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Microsoft-Connect-300x135.png" alt="Microsoft Connect" width="300" height="135" /></a><br />
</center></p>
<p>When you receive your access token, you can begin creating projects on the Azure platform with the <a href="https://windows.azure.com">Azure Developer Portal</a>. You can only create one project with the CTP, but you can have multiple services inside each project (<em>web/worker roles</em>).<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Projects.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-515" title="Azure Projects" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Projects-300x86.png" alt="Azure Projects" width="300" height="86" /></a><br />
</center></p>
<p>After you&#8217;ve created your project in the developer portal, you can add services which will be the endpoints you deploy to for Windows Azure. We will add a Windows Azure Service in this example.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Windows-Azure-Add-Service.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-517" title="Windows Azure Add Service" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Windows-Azure-Add-Service-300x137.png" alt="Windows Azure Add Service" width="300" height="137" /></a><br />
</center></p>
<p>To create our Windows Azure application, we need to create a package (cspkg) that contains our application contents and a configuration definition (cscfg) that defines our roles. Microsoft has created Azure tools to assist in generating the package and configuration file. You can download the <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=8d75d4f7-77a4-4adf-bce8-1b10608574bb&amp;displaylang=en">Azure SDK</a> to create Azure applications using Visual Studio. The <a href="http://www.microsoft.com/downloads/details.aspx?familyid=AA40F3E2-AFC5-484D-B4E9-6A5227E73590&amp;displaylang=en">Azure SDK</a> allows you to run your own local development fabric before pushing your application into the cloud. <a href="http://eclipse.org/">Eclipse</a> also has its own <a href="http://www.windowsazure4e.org/">Azure Tools</a> if you prefer to develop in the Eclipse environment.</p>
<p>After installation of the Azure Tools, you now have a new project template &#8220;Cloud Service&#8221; which we&#8217;ll use to create our web role.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Visual-Studio-Cloud-Service-Template.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-519" title="Visual Studio Cloud Service Template" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Visual-Studio-Cloud-Service-Template-300x200.png" alt="Visual Studio Cloud Service Template" width="300" height="200" /></a><br />
</center><br />
After providing a name for your Cloud Service project, you are prompted to select which roles you would like to use. We will choose &#8220;ASP.NET Web Role&#8221; for this example.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Roles.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-522" title="Azure Roles" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Roles-300x188.png" alt="Azure Roles" width="300" height="188" /></a><br />
</center></p>
<p>After clicking &#8220;Ok&#8221;, you will now have a Cloud Service project and a Web Role project in your solution. We will now remove the Web Role for this exercise, and replace it with an existing ASP.NET application called <a href="http://weblogs.asp.net/scottgu/archive/2008/11/24/new-asp-net-charting-control-lt-asp-chart-runat-quot-server-quot-gt.aspx">ASP.NET Chart Controls</a> which Scott Guthrie announced last year. This application did not work on the PDC release of Azure, but Azure now allows web applications to run in Full Trust with some <a href="http://blogs.msdn.com/windowsazure/archive/2009/03/18/hosting-roles-under-net-full-trust.aspx">minor tweaking</a>.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/ASP.NET-Chart-Controls-Solution.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="size-medium wp-image-524" title="ASP.NET Chart Controls Solution" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/ASP.NET-Chart-Controls-Solution-189x300.png" alt="ASP.NET Chart Controls Solution" width="95" height="150" /></a><br />
</center></p>
<p>We now have our solution complete and have one web role we would like to deploy to the cloud. We must now publish the solution to Azure. We right-click on the Cloud Service project and click &#8220;Publish&#8221; which opens up the <a href="http://windows.azure.com">Azure Developer Portal</a>.</p>
<p>After logging in with Windows Live, you want to deploy your application to the Staging Environment before pushing it live. To deploy, you simply select the application package (cspkg) and configuration definition (cscfg) from your &#8220;/publish&#8221; folder in the cloud service &#8220;/bin/Debug&#8221; directory.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Package-and-Configuration-Selection.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-530" title="Azure Package and Configuration Selection" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Package-and-Configuration-Selection-300x113.png" alt="Azure Package and Configuration Selection" width="300" height="113" /></a><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Package-and-Configuration.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-527" title="Azure Package and Configuration" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Package-and-Configuration-300x26.png" alt="Azure Package and Configuration" width="300" height="26" /></a><br />
</center></p>
<p>Clicking on &#8220;Deploy&#8221; will load the Azure package and service definition to the cloud and create a VM necessary to run the application. The environment takes some time to setup and will show its state as &#8220;Initialization&#8221; until the VM is entirely ready. You are given a URI based upon a randomly generated GUID to view your application and test it before moving it into production. Having two environments is nice if you also have database changes that need to coincide with your deployment.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Staging-Environment.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-537" title="Azure Staging Environment" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/Azure-Staging-Environment-300x226.png" alt="Azure Staging Environment" width="300" height="226" /></a><br />
</center></p>
<p>Once the application has been verified, you can click the center arrows icon to swap the Staging site into Production. You can see the two environments have now been switched.<br />
<center><br />
<a href="http://blog.pearltechnology.com/wp-content/uploads/2009/11/ASP.NET-Chart-Controls-Azure.png#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="aligncenter size-medium wp-image-538" title="ASP.NET Chart Controls Azure" src="http://blog.pearltechnology.com/wp-content/uploads/2009/11/ASP.NET-Chart-Controls-Azure-300x212.png" alt="ASP.NET Chart Controls Azure" width="300" height="212" /></a><br />
</center></p>
<p>Azure does make the deployment process a bit more involved, but there is an <a href="http://blogs.msdn.com/windowsazure/archive/2009/09/17/introducing-the-windows-azure-service-management-api.aspx">managed Azure Deployment API</a> in the works to automate the build and deploy steps you may need in your organization. You can <a href="http://aspchartcontrols.cloudapp.net/">view</a> our sample ASP.NET Chart Controls application running on Azure Services (<em>cloudapp.net</em>). Kudos to Microsoft for allowing full trust applications! We will be watching for more exciting features from the <a href="http://blogs.msdn.com/windowsazure/">Azure Team</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.pearltechnology.com/deploying-to-windows-azure/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
