<?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>dmacias . org &#187; Technology</title>
	<atom:link href="http://dmacias.org/category/technology/feed/" rel="self" type="application/rss+xml" />
	<link>http://dmacias.org</link>
	<description>Not quite crazy not quite sane.</description>
	<lastBuildDate>Sun, 22 Apr 2012 23:49:01 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Cisco CUIC 8.x More Value List and Collections</title>
		<link>http://dmacias.org/2012/04/13/cisco-cuic-8-x-more-value-list-and-collections/</link>
		<comments>http://dmacias.org/2012/04/13/cisco-cuic-8-x-more-value-list-and-collections/#comments</comments>
		<pubDate>Sat, 14 Apr 2012 02:40:41 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Cisco CUIC 8.x]]></category>

		<guid isPermaLink="false">http://dmacias.org/?p=518</guid>
		<description><![CDATA[I wanted to make a clarification to my earlier post about Value Lists and Collections.&#160; This post will explain how to create a new Value List which will retrieve agents who have a specific value in their Agent.Description field.&#160; Then Collections can be used to extract other more specific agents.&#160; This could be used to [...]]]></description>
			<content:encoded><![CDATA[<p>I wanted to make a clarification to my earlier post about Value Lists and Collections.&#160; This post will explain how to create a new Value List which will retrieve agents who have a specific value in their Agent.Description field.&#160; Then Collections can be used to extract other more specific agents.&#160; This could be used to retrieve agents from a single peripheral or agents named David, etc..&#160; First, here’s the Value List:</p>
<p><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="Value List" border="0" alt="Value List" src="http://dmacias.org/wp-content/uploads/2012/04/Value-List.png" width="514" height="484" /></p>
<p>And finally here’s a Collection:</p>
<p><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="Collection" border="0" alt="Collection" src="http://dmacias.org/wp-content/uploads/2012/04/Collection.png" width="644" height="439" /></p>
<p>Hope this makes sense and will help you create your own Value List and Collections.</p>
<p>~david</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2012/04/13/cisco-cuic-8-x-more-value-list-and-collections/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cisco CUIC Creating Value Lists and Collections</title>
		<link>http://dmacias.org/2012/03/14/cisco-cuic-creating-value-lists-and-collections/</link>
		<comments>http://dmacias.org/2012/03/14/cisco-cuic-creating-value-lists-and-collections/#comments</comments>
		<pubDate>Wed, 14 Mar 2012 08:35:37 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[cuic]]></category>
		<category><![CDATA[reporting]]></category>

		<guid isPermaLink="false">http://dmacias.org/?p=507</guid>
		<description><![CDATA[This one should be pretty simple, but figure I would add it here for posterity’s sake.&#160; I wanted to setup a real time Value List of all the call types, then break down my Value List into smaller Collections for each specific type of call type. First step is to log in to CUIC and [...]]]></description>
			<content:encoded><![CDATA[<p>This one should be pretty simple, but figure I would add it here for posterity’s sake.&#160; I wanted to setup a real time Value List of all the call types, then break down my Value List into smaller Collections for each specific type of call type.</p>
<p>First step is to log in to CUIC and got to Value Lists and click on Create.</p>
<p><a href="http://dmacias.org/wp-content/uploads/2012/03/Untitled.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="Untitled" border="0" alt="Untitled" src="http://dmacias.org/wp-content/uploads/2012/03/Untitled_thumb.png" width="644" height="364" /></a></p>
<p>The Value List Query:</p>
<div class="csharpcode">
<pre class="alt"><span class="kwrd">SELECT</span> Call_Type.CallTypeID <span class="kwrd">AS</span> ID, Call_Type.EnterpriseName <span class="kwrd">AS</span> <span class="kwrd">VALUE</span> <span class="kwrd">FROM</span> Call_Type (nolock) </pre>
<pre><span class="kwrd">Order</span> <span class="kwrd">by</span> Call_Type.EnterpriseName</pre>
</div>
<style type="text/css">
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p>The Collection Query:</p>
<div class="csharpcode">
<pre class="alt"><span class="kwrd">SELECT</span> Call_Type.CallTypeID <span class="kwrd">AS</span> ID, Call_Type.EnterpriseName <span class="kwrd">AS</span> <span class="kwrd">VALUE</span> <span class="kwrd">FROM</span> Call_Type (nolock) </pre>
<pre><span class="kwrd">WHERE</span> Call_Type.CustomerDefinitionID = (<span class="kwrd">SELECT</span> User_Group.CustomerDefinitionID <span class="kwrd">FROM</span> User_Group (nolock) </pre>
<pre class="alt"><span class="kwrd">WHERE</span> <span class="kwrd">UPPER</span>(User_Group.UserGroupName) = <span class="kwrd">UPPER</span>(&lt;COLLECTIONIDENTIFIER&gt;)) <span class="kwrd">OR</span> (<span class="kwrd">SELECT</span> <span class="kwrd">COUNT</span>(User_Group.CustomerDefinitionID) </pre>
<pre><span class="kwrd">FROM</span> User_Group (nolock) <span class="kwrd">WHERE</span> <span class="kwrd">UPPER</span>(User_Group.UserGroupName) = <span class="kwrd">UPPER</span>(&lt;COLLECTIONIDENTIFIER&gt;)) = 0 <span class="kwrd">ORDER</span> <span class="kwrd">BY</span> Call_Type.EnterpriseName ASC</pre>
</div>
<p>Validate your query and save.</p>
<p>Second, click on your Value List and click on Collections.</p>
<p><a href="http://dmacias.org/wp-content/uploads/2012/03/Untitled1.png"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="Untitled1" border="0" alt="Untitled1" src="http://dmacias.org/wp-content/uploads/2012/03/Untitled1_thumb.png" width="644" height="364" /></a></p>
<p>Notice the Collection Type of Wildcard which allows your create a wildcard which references all your call types.&#160; This could be French* or CustomerService*.&#160; Hit Save, Populate Values, and confirm the values to ensure the collection has the call types you’re looking for.</p>
<p>~dmacias</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2012/03/14/cisco-cuic-creating-value-lists-and-collections/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cisco CUIC Real Time Agent Report with Not Ready Reason Code</title>
		<link>http://dmacias.org/2012/03/12/cisco-cuic-real-time-agent-report-with-not-ready-reason-code/</link>
		<comments>http://dmacias.org/2012/03/12/cisco-cuic-real-time-agent-report-with-not-ready-reason-code/#comments</comments>
		<pubDate>Tue, 13 Mar 2012 01:48:23 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[cuic]]></category>
		<category><![CDATA[reporting]]></category>

		<guid isPermaLink="false">http://dmacias.org/?p=500</guid>
		<description><![CDATA[I had my first exposure to CUIC last week and was glad to finally see this product and get to play with it.&#160; For the most part it looks just like CUIS, except for the whole appliance model.&#160; The UI is a little more streamlined, but what I remember from CUIS, it’s all there.&#160; Now, [...]]]></description>
			<content:encoded><![CDATA[<p>I had my first exposure to CUIC last week and was glad to finally see this product and get to play with it.&#160; For the most part it looks just like CUIS, except for the whole appliance model.&#160; The UI is a little more streamlined, but what I remember from CUIS, it’s all there.&#160; Now, one big change is that with CUIC, reports are cut down to a standard set (20 if I remember correctly) as opposed to the dozens of reports available through WebView.&#160; This created some initial confusion as you try to familiarize yourself with what kind of data the new reports have.&#160; Perhaps the best feature is the ability to remove columns from reports and just display the data you want to see.</p>
<p>One report which comes up all the time is an agent real time report showing the agent’s current not ready reason code.&#160; I have an SQL query I use to get this data myself, but now that CUIC is supposed to make it easier to create your own reports, I wanted to give it a shot and create my very first custom report.</p>
<p>First, let’s start with the SQL query which joins the real time agent states as well as reason code tables.</p>
<div class="csharpcode">
<pre class="alt"><span class="lnum">   1:  </span><span class="kwrd">SELECT</span> [awdb].[dbo].[t_Agent_Real_Time].[SkillTargetID]</pre>
<pre><span class="lnum">   2:  </span>        ,[awdb].[dbo].[t_Agent].[EnterpriseName]</pre>
<pre class="alt"><span class="lnum">   3:  </span>      ,[DateTime]</pre>
<pre><span class="lnum">   4:  </span>      ,[SkillGroupSkillTargetID]</pre>
<pre class="alt"><span class="lnum">   5:  </span>      ,[ServiceSkillTargetID]</pre>
<pre><span class="lnum">   6:  </span>      ,[AgentState]</pre>
<pre class="alt"><span class="lnum">   7:  </span>      ,<span class="str">'Agent State'</span> =</pre>
<pre><span class="lnum">   8:  </span>            <span class="kwrd">CASE</span></pre>
<pre class="alt"><span class="lnum">   9:  </span>                  <span class="kwrd">WHEN</span> [AgentState] = 2 <span class="kwrd">THEN</span> <span class="str">'Not Ready'</span></pre>
<pre><span class="lnum">  10:  </span>                  <span class="kwrd">WHEN</span> [AgentState] = 3 <span class="kwrd">THEN</span> <span class="str">'Ready'</span></pre>
<pre class="alt"><span class="lnum">  11:  </span>                  <span class="kwrd">WHEN</span> [AgentState] = 4 <span class="kwrd">THEN</span> <span class="str">'Talking'</span></pre>
<pre><span class="lnum">  12:  </span>                  <span class="kwrd">WHEN</span> [AgentState] = 5 <span class="kwrd">THEN</span> <span class="str">'Wrap Up'</span></pre>
<pre class="alt"><span class="lnum">  13:  </span>            <span class="kwrd">END</span></pre>
<pre><span class="lnum">  14:  </span>      ,[awdb].[dbo].[t_Agent_Real_Time].[ReasonCode]</pre>
<pre class="alt"><span class="lnum">  15:  </span>      ,[awdb].[dbo].[t_Reason_Code].[ReasonText]</pre>
<pre><span class="lnum">  16:  </span>      ,[Extension]</pre>
<pre class="alt"><span class="lnum">  17:  </span>      ,[DateTimeLastStateChange]</pre>
<pre><span class="lnum">  18:  </span>  <span class="kwrd">FROM</span> [awdb].[dbo].[t_Agent_Real_Time] </pre>
<pre class="alt"><span class="lnum">  19:  </span>  <span class="kwrd">JOIN</span> [awdb].[dbo].[t_Reason_Code] <span class="kwrd">ON</span> ([awdb].[dbo].[t_Agent_Real_Time].[ReasonCode]=[awdb].[dbo].[t_Reason_Code].[ReasonCode])</pre>
<pre><span class="lnum">  20:  </span>  <span class="kwrd">JOIN</span> [awdb].[dbo].[t_Agent] <span class="kwrd">ON</span> [awdb].[dbo].[t_Agent_Real_Time].[SkillTargetID] = [awdb].[dbo].[t_Agent].[SkillTargetID]</pre>
<pre class="alt"><span class="lnum">  21:  </span>GO</pre>
</div>
<style type="text/css">
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p>Now, don’t judge me on a) the poor SQL writing skills or b) my affinity to spacing.&#160; It’s important to understand what the above query is doing to ensure you know where your reason codes are coming from.</p>
<p>Second, you will need to create a new report definition based on the stock Agent Real Time report definition.&#160; You will need to extract the SQL of the report query shown below.</p>
<blockquote>
<p>SELECT Agent.EnterpriseName, full_name=(Person.LastName + &#8216;, &#8216; + Person.FirstName) , Skill_Group.EnterpriseName as SkillName, Agent.SkillTargetID, Agent_Real_Time.DateTime, Datepart(yy, Agent_Real_Time.DateTime) as Year, Datepart(mm, Agent_Real_Time.DateTime) as Month, Datepart(ww, Agent_Real_Time.DateTime) as Week, Datepart(dy, Agent_Real_Time.DateTime) as DOY, Datepart(dw, Agent_Real_Time.DateTime) as DOW, CONVERT(char(10),Agent_Real_Time.DateTime,101) as DATE, Agent_Real_Time.SkillGroupSkillTargetID, ServiceName = Service.EnterpriseName, Media = Media_Routing_Domain.EnterpriseName, CASE Agent_Real_Time.AgentState WHEN 0 THEN &#8216;Logged Out&#8217; WHEN 1 THEN &#8216;Logged On&#8217; WHEN 2 THEN &#8216;Not Ready&#8217; WHEN 3 THEN &#8216;Ready&#8217; WHEN 4 THEN &#8216;Talking&#8217; WHEN 5 THEN &#8216;Work Not Ready&#8217; WHEN 6 THEN &#8216;Work Ready&#8217; WHEN 7 THEN &#8216;Busy Other&#8217; WHEN 8 THEN &#8216;Reserved&#8217; WHEN 9 THEN &#8216;Unknown&#8217; WHEN 10 THEN &#8216;Hold&#8217; WHEN 11 THEN &#8216;Active&#8217; WHEN 12 THEN &#8216;Paused&#8217; WHEN 13 THEN &#8216;Interrupted&#8217; WHEN 14 THEN &#8216;Not Active&#8217; ELSE CONVERT(VARCHAR, Agent_Real_Time.AgentState) END AgentState, CASE Agent_Real_Time.PhoneType When 0 THEN &#8216;Not Mobile&#8217; WHEN 1 THEN &#8216;Call By Call&#8217; WHEN 2 THEN &#8216;Nailed Connection&#8217; Else &#8216;Not Applicable&#8217; END phonetypetext, remotephonenumber = Agent_Real_Time.RemotePhoneNumber, ReasonCode = CASE WHEN Agent_Real_Time.ReasonCode = 0 THEN &#8216;NONE&#8217; ELSE CONVERT(VARCHAR, Agent_Real_Time.ReasonCode) END , Agent_Real_Time.Extension, Agent_Real_Time.DateTimeLastStateChange, Agent_Real_Time.DateTimeLogin, CASE WHEN RequestedSupervisorAssist = 1 THEN &#8216;Yes&#8217; ELSE &#8216;No&#8217; END RequestedSupervisorAssist, CASE Agent_Real_Time.Destination WHEN 1 THEN &#8216;ACD&#8217; WHEN 2 THEN &#8216;Direct&#8217; WHEN 3 THEN &#8216;Auto Out&#8217; WHEN 4 THEN &#8216;Reserve&#8217; WHEN 5 THEN &#8216;Preview&#8217; ELSE &#8216;Not Applicable&#8217; END Destination, CASE Agent_Real_Time.Direction WHEN 1 THEN &#8216;In&#8217; WHEN 2 THEN &#8216;Out&#8217; WHEN 3 THEN &#8216;Other&#8217; ELSE &#8216;Not Applicable&#8217; END Direction, CASE WHEN Agent_Real_Time.OnHold = 1 THEN &#8216;Yes&#8217; ELSE &#8216;No&#8217; END OnHold, Agent_Real_Time.NetworkTargetID, Agent_Real_Time.AgentStatus, Agent_Real_Time.CustomerPhoneNumber, Agent_Real_Time.CustomerAccountNumber, Agent_Real_Time.CampaignID, Agent_Real_Time.QueryRuleID, Duration = DATEDIFF(ss, Agent_Real_Time.DateTimeLastStateChange, CASE WHEN (DATEDIFF(ss, Agent_Real_Time.DateTimeLastStateChange, (SELECT NowTime from Controller_Time (nolock))) &lt;= 0 ) THEN Agent_Real_Time.DateTimeLastStateChange ELSE(SELECT NowTime FROM Controller_Time (nolock)) END), CASE WHEN Agent_Real_Time.Routable = 1 THEN &#8216;Yes&#8217; ELSE &#8216;No&#8217; END RoutableText,Agent_Real_Time.DateTimeLastModeChange, Agent_Real_Time.CallInProgress, Agent_Real_Time.MaxTasks, CASE WHEN Agent_Real_Time.AvailableInMRD = 0 THEN &#8216;No&#8217; WHEN Agent_Real_Time.AvailableInMRD = 1 THEN &#8216;Yes_ICM&#8217; WHEN Agent_Real_Time.AvailableInMRD = 2 THEN &#8216;Yes_APP&#8217; ELSE &#8216;No&#8217; END AvailInMRDText, Agent_Real_Time.DateTimeTaskLevelChange, Agent_Real_Time.RouterCallsQueueNow, Agent_Real_Time.RouterLongestCallQ FROM Agent (nolock), Person (nolock), Media_Routing_Domain (nolock), Agent_Real_Time (nolock) LEFT JOIN Service (nolock) ON Agent_Real_Time.ServiceSkillTargetID = Service.SkillTargetID, Skill_Group WHERE ( Agent_Real_Time.SkillGroupSkillTargetID = Skill_Group.SkillTargetID) and Agent.PersonID=Person.PersonID and Media_Routing_Domain.MRDomainID = Agent_Real_Time.MRDomainID and ( Agent.SkillTargetID = Agent_Real_Time.SkillTargetID ) UNION SELECT Agent.EnterpriseName, full_name=(Person.LastName + &#8216;, &#8216; + Person.FirstName) , convert(varchar,&#8217;Not Applicable&#8217;), Agent_Real_Time.SkillTargetID, Agent_Real_Time.DateTime, Datepart(yy, Agent_Real_Time.DateTime) as Year, Datepart(mm, Agent_Real_Time.DateTime) as Month, Datepart(ww, Agent_Real_Time.DateTime) as Week, Datepart(dy, Agent_Real_Time.DateTime) as DOY, Datepart(dw, Agent_Real_Time.DateTime) as DOW, CONVERT(char(10),Agent_Real_Time.DateTime,101) as DATE, Agent_Real_Time.SkillGroupSkillTargetID, ServiceName = Service.EnterpriseName, Media=Media_Routing_Domain.EnterpriseName, CASE Agent_Real_Time.AgentState WHEN 0 THEN &#8216;Logged Out&#8217; WHEN 1 THEN &#8216;Logged On&#8217; WHEN 2 THEN &#8216;Not Ready&#8217; WHEN 3 THEN &#8216;Ready&#8217; WHEN 4 THEN &#8216;Talking&#8217; WHEN 5 THEN &#8216;Work Not Ready&#8217; WHEN 6 THEN &#8216;Work Ready&#8217; WHEN 7 THEN &#8216;Busy Other&#8217; WHEN 8 THEN &#8216;Reserved&#8217; WHEN 9 THEN &#8216;Unknown&#8217; WHEN 10 THEN &#8216;Hold&#8217; WHEN 11 THEN &#8216;Active&#8217; WHEN 12 THEN &#8216;Paused&#8217; WHEN 13 THEN &#8216;Interrupted&#8217; WHEN 14 THEN &#8216;Not Active&#8217; ELSE CONVERT(VARCHAR, Agent_Real_Time.AgentState) END AgentState, CASE Agent_Real_Time.PhoneType When 0 THEN &#8216;Not Mobile&#8217;WHEN 1 THEN &#8216;Call By Call&#8217; WHEN 2 THEN &#8216;Nailed Connection&#8217; Else &#8216;Not Applicable&#8217; END phonetypetext, remotephonenumber = Agent_Real_Time.RemotePhoneNumber, ReasonCode = CASE WHEN Agent_Real_Time.ReasonCode = 0 THEN &#8216;NONE&#8217; ELSE CONVERT(VARCHAR, Agent_Real_Time.ReasonCode) END , Agent_Real_Time.Extension, Agent_Real_Time.DateTimeLastStateChange, Agent_Real_Time.DateTimeLogin, CASE WHEN RequestedSupervisorAssist = 1 THEN &#8216;Yes&#8217; ELSE &#8216;No&#8217; END RequestedSupervisorAssist, CASE Agent_Real_Time.Destination WHEN 1 THEN &#8216;ACD&#8217; WHEN 2 THEN &#8216;Direct&#8217; WHEN 3 THEN &#8216;Auto Out&#8217; WHEN 4 THEN &#8216;Reserve&#8217; WHEN 5 THEN &#8216;Preview&#8217; ELSE &#8216;Not Applicable&#8217; END Destination, CASE Agent_Real_Time.Direction WHEN 1 THEN &#8216;In&#8217; WHEN 2 THEN &#8216;Out&#8217; WHEN 3 THEN &#8216;Other&#8217; ELSE &#8216;Not Applicable&#8217; END Direction, CASE WHEN Agent_Real_Time.OnHold = 1 THEN &#8216;Yes&#8217; ELSE &#8216;No&#8217; END OnHold, Agent_Real_Time.NetworkTargetID, Agent_Real_Time.AgentStatus, Agent_Real_Time.CustomerPhoneNumber, Agent_Real_Time.CustomerAccountNumber, Agent_Real_Time.CampaignID, Agent_Real_Time.QueryRuleID, Duration=DATEDIFF(ss, Agent_Real_Time.DateTimeLastStateChange, CASE WHEN (DATEDIFF(ss, Agent_Real_Time.DateTimeLastStateChange, (SELECT NowTime from Controller_Time (nolock))) &lt;= 0 ) THEN Agent_Real_Time.DateTimeLastStateChange ELSE (SELECT NowTime FROM Controller_Time (nolock)) END), CASE WHEN Agent_Real_Time.Routable = 1 THEN &#8216;Yes&#8217; ELSE &#8216;No&#8217; END RoutableText , Agent_Real_Time.DateTimeLastModeChange, Agent_Real_Time.CallInProgress, Agent_Real_Time.MaxTasks, CASE WHEN Agent_Real_Time.AvailableInMRD = 0 THEN &#8216;No&#8217; WHEN Agent_Real_Time.AvailableInMRD = 1 THEN &#8216;Yes_ICM&#8217; WHEN Agent_Real_Time.AvailableInMRD = 2 THEN &#8216;Yes_APP&#8217; ELSE &#8216;No&#8217; END AvailInMRDText, Agent_Real_Time.DateTimeTaskLevelChange, Agent_Real_Time.RouterCallsQueueNow, Agent_Real_Time.RouterLongestCallQ FROM Agent (nolock), Person (nolock), Media_Routing_Domain (nolock), Agent_Real_Time (nolock) LEFT JOIN Service (nolock) ON Agent_Real_Time.ServiceSkillTargetID = Service.SkillTargetID WHERE ((Agent_Real_Time.SkillGroupSkillTargetID = 0) OR (Agent_Real_Time.SkillGroupSkillTargetID IS NULL)) and Agent.PersonID=Person.PersonID and Media_Routing_Domain.MRDomainID = Agent_Real_Time.MRDomainID and ( Agent.SkillTargetID = Agent_Real_Time.SkillTargetID )</p>
</blockquote>
<p>Third, modify the SQL query.&#160; Also, it helps a lot to actually arrange the above query and break it down section by section.</p>
<p>&#160;</p>
<div class="csharpcode">
<pre class="alt"><span class="lnum">   1:  </span>&#160;</pre>
<pre><span class="lnum">   2:  </span><span class="kwrd">SELECT</span> </pre>
<pre class="alt"><span class="lnum">   3:  </span>                Agent.EnterpriseName, </pre>
<pre><span class="lnum">   4:  </span>                full_name=(Person.LastName + <span class="str">', '</span> + Person.FirstName), </pre>
<pre class="alt"><span class="lnum">   5:  </span>                Skill_Group.EnterpriseName <span class="kwrd">as</span> SkillName, </pre>
<pre><span class="lnum">   6:  </span>                Agent.SkillTargetID, </pre>
<pre class="alt"><span class="lnum">   7:  </span>                Agent_Real_Time.DateTime, </pre>
<pre><span class="lnum">   8:  </span>                Datepart(yy, Agent_Real_Time.DateTime) <span class="kwrd">as</span> <span class="kwrd">Year</span>, </pre>
<pre class="alt"><span class="lnum">   9:  </span>                Datepart(mm, Agent_Real_Time.DateTime) <span class="kwrd">as</span> <span class="kwrd">Month</span>, </pre>
<pre><span class="lnum">  10:  </span>                Datepart(ww, Agent_Real_Time.DateTime) <span class="kwrd">as</span> Week, </pre>
<pre class="alt"><span class="lnum">  11:  </span>                Datepart(dy, Agent_Real_Time.DateTime) <span class="kwrd">as</span> DOY, </pre>
<pre><span class="lnum">  12:  </span>                Datepart(dw, Agent_Real_Time.DateTime) <span class="kwrd">as</span> DOW, </pre>
<pre class="alt"><span class="lnum">  13:  </span>                <span class="kwrd">CONVERT</span>(<span class="kwrd">char</span>(10),Agent_Real_Time.DateTime,101) <span class="kwrd">as</span> <span class="kwrd">DATE</span>, Agent_Real_Time.SkillGroupSkillTargetID, </pre>
<pre><span class="lnum">  14:  </span>                ServiceName = Service.EnterpriseName, </pre>
<pre class="alt"><span class="lnum">  15:  </span>                Media = Media_Routing_Domain.EnterpriseName, </pre>
<pre><span class="lnum">  16:  </span>                <span class="kwrd">CASE</span> Agent_Real_Time.AgentState  </pre>
<pre class="alt"><span class="lnum">  17:  </span>                                <span class="kwrd">WHEN</span> 0 <span class="kwrd">THEN</span> <span class="str">'Logged Out'</span> </pre>
<pre><span class="lnum">  18:  </span>                                <span class="kwrd">WHEN</span> 1 <span class="kwrd">THEN</span> <span class="str">'Logged On'</span> </pre>
<pre class="alt"><span class="lnum">  19:  </span>                                <span class="kwrd">WHEN</span> 2 <span class="kwrd">THEN</span> <span class="str">'Not Ready'</span> </pre>
<pre><span class="lnum">  20:  </span>                                <span class="kwrd">WHEN</span> 3 <span class="kwrd">THEN</span> <span class="str">'Ready'</span> </pre>
<pre class="alt"><span class="lnum">  21:  </span>                                <span class="kwrd">WHEN</span> 4 <span class="kwrd">THEN</span> <span class="str">'Talking'</span> </pre>
<pre><span class="lnum">  22:  </span>                                <span class="kwrd">WHEN</span> 5 <span class="kwrd">THEN</span> <span class="str">'Work Not Ready'</span> </pre>
<pre class="alt"><span class="lnum">  23:  </span>                                <span class="kwrd">WHEN</span> 6 <span class="kwrd">THEN</span> <span class="str">'Work Ready'</span> </pre>
<pre><span class="lnum">  24:  </span>                                <span class="kwrd">WHEN</span> 7 <span class="kwrd">THEN</span> <span class="str">'Busy Other'</span> </pre>
<pre class="alt"><span class="lnum">  25:  </span>                                <span class="kwrd">WHEN</span> 8 <span class="kwrd">THEN</span> <span class="str">'Reserved'</span>  </pre>
<pre><span class="lnum">  26:  </span>                                <span class="kwrd">WHEN</span> 9 <span class="kwrd">THEN</span> <span class="str">'Unknown'</span> </pre>
<pre class="alt"><span class="lnum">  27:  </span>                                <span class="kwrd">WHEN</span> 10 <span class="kwrd">THEN</span> <span class="str">'Hold'</span> </pre>
<pre><span class="lnum">  28:  </span>                                <span class="kwrd">WHEN</span> 11 <span class="kwrd">THEN</span> <span class="str">'Active'</span>  </pre>
<pre class="alt"><span class="lnum">  29:  </span>                                <span class="kwrd">WHEN</span> 12 <span class="kwrd">THEN</span> <span class="str">'Paused'</span> </pre>
<pre><span class="lnum">  30:  </span>                                <span class="kwrd">WHEN</span> 13 <span class="kwrd">THEN</span> <span class="str">'Interrupted'</span> </pre>
<pre class="alt"><span class="lnum">  31:  </span>                                <span class="kwrd">WHEN</span> 14 <span class="kwrd">THEN</span> <span class="str">'Not Active'</span> </pre>
<pre><span class="lnum">  32:  </span>                                <span class="kwrd">ELSE</span> <span class="kwrd">CONVERT</span>(<span class="kwrd">VARCHAR</span>, Agent_Real_Time.AgentState) </pre>
<pre class="alt"><span class="lnum">  33:  </span>                <span class="kwrd">END</span> AgentState, </pre>
<pre><span class="lnum">  34:  </span>                <span class="kwrd">CASE</span> Agent_Real_Time.PhoneType </pre>
<pre class="alt"><span class="lnum">  35:  </span>                                <span class="kwrd">When</span> 0 <span class="kwrd">THEN</span> <span class="str">'Not Mobile'</span> </pre>
<pre><span class="lnum">  36:  </span>                                <span class="kwrd">WHEN</span> 1 <span class="kwrd">THEN</span> <span class="str">'Call By Call'</span> </pre>
<pre class="alt"><span class="lnum">  37:  </span>                                <span class="kwrd">WHEN</span> 2 <span class="kwrd">THEN</span> <span class="str">'Nailed Connection'</span> </pre>
<pre><span class="lnum">  38:  </span>                                <span class="kwrd">Else</span> <span class="str">'Not Applicable'</span> </pre>
<pre class="alt"><span class="lnum">  39:  </span>                <span class="kwrd">END</span> phonetypetext, </pre>
<pre><span class="lnum">  40:  </span>                remotephonenumber = Agent_Real_Time.RemotePhoneNumber, </pre>
<pre class="alt"><span class="lnum">  41:  </span>                ReasonCode = <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum">  42:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.ReasonCode = 0 </pre>
<pre class="alt"><span class="lnum">  43:  </span>                                <span class="kwrd">THEN</span> <span class="str">'NONE'</span> </pre>
<pre><span class="lnum">  44:  </span>                                <span class="kwrd">ELSE</span> <span class="kwrd">CONVERT</span>(<span class="kwrd">VARCHAR</span>, Agent_Real_Time.ReasonCode) </pre>
<pre class="alt"><span class="lnum">  45:  </span>                                <span class="kwrd">END</span> , </pre>
<pre><span class="lnum">  46:  </span>                Reason_Code.ReasonText,</pre>
<pre class="alt"><span class="lnum">  47:  </span>                Agent_Real_Time.Extension, </pre>
<pre><span class="lnum">  48:  </span>                Agent_Real_Time.DateTimeLastStateChange, </pre>
<pre class="alt"><span class="lnum">  49:  </span>                Agent_Real_Time.DateTimeLogin, </pre>
<pre><span class="lnum">  50:  </span>                <span class="kwrd">CASE</span> </pre>
<pre class="alt"><span class="lnum">  51:  </span>                                <span class="kwrd">WHEN</span> RequestedSupervisorAssist = 1 <span class="kwrd">THEN</span> <span class="str">'Yes'</span> <span class="kwrd">ELSE</span> <span class="str">'No'</span> </pre>
<pre><span class="lnum">  52:  </span>                <span class="kwrd">END</span> RequestedSupervisorAssist, </pre>
<pre class="alt"><span class="lnum">  53:  </span>                <span class="kwrd">CASE</span> Agent_Real_Time.Destination </pre>
<pre><span class="lnum">  54:  </span>                                <span class="kwrd">WHEN</span> 1 <span class="kwrd">THEN</span> <span class="str">'ACD'</span> </pre>
<pre class="alt"><span class="lnum">  55:  </span>                                <span class="kwrd">WHEN</span> 2 <span class="kwrd">THEN</span> <span class="str">'Direct'</span> </pre>
<pre><span class="lnum">  56:  </span>                                <span class="kwrd">WHEN</span> 3 <span class="kwrd">THEN</span> <span class="str">'Auto Out'</span> </pre>
<pre class="alt"><span class="lnum">  57:  </span>                                <span class="kwrd">WHEN</span> 4 <span class="kwrd">THEN</span> <span class="str">'Reserve'</span> </pre>
<pre><span class="lnum">  58:  </span>                                <span class="kwrd">WHEN</span> 5 <span class="kwrd">THEN</span> <span class="str">'Preview'</span> </pre>
<pre class="alt"><span class="lnum">  59:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'Not Applicable'</span> </pre>
<pre><span class="lnum">  60:  </span>                <span class="kwrd">END</span> Destination, </pre>
<pre class="alt"><span class="lnum">  61:  </span>                <span class="kwrd">CASE</span>  Agent_Real_Time.Direction </pre>
<pre><span class="lnum">  62:  </span>                                <span class="kwrd">WHEN</span> 1 <span class="kwrd">THEN</span> <span class="str">'In'</span> </pre>
<pre class="alt"><span class="lnum">  63:  </span>                                <span class="kwrd">WHEN</span> 2 <span class="kwrd">THEN</span> <span class="str">'Out'</span> </pre>
<pre><span class="lnum">  64:  </span>                                <span class="kwrd">WHEN</span> 3 <span class="kwrd">THEN</span> <span class="str">'Other'</span> </pre>
<pre class="alt"><span class="lnum">  65:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'Not Applicable'</span> </pre>
<pre><span class="lnum">  66:  </span>                <span class="kwrd">END</span> Direction, </pre>
<pre class="alt"><span class="lnum">  67:  </span>                <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum">  68:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.OnHold = 1 <span class="kwrd">THEN</span> <span class="str">'Yes'</span> </pre>
<pre class="alt"><span class="lnum">  69:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'No'</span> </pre>
<pre><span class="lnum">  70:  </span>                <span class="kwrd">END</span> OnHold, </pre>
<pre class="alt"><span class="lnum">  71:  </span>                Agent_Real_Time.NetworkTargetID, </pre>
<pre><span class="lnum">  72:  </span>                Agent_Real_Time.AgentStatus, </pre>
<pre class="alt"><span class="lnum">  73:  </span>                Agent_Real_Time.CustomerPhoneNumber, </pre>
<pre><span class="lnum">  74:  </span>                Agent_Real_Time.CustomerAccountNumber, </pre>
<pre class="alt"><span class="lnum">  75:  </span>                Agent_Real_Time.CampaignID, </pre>
<pre><span class="lnum">  76:  </span>                Agent_Real_Time.QueryRuleID, </pre>
<pre class="alt"><span class="lnum">  77:  </span>                Duration = DATEDIFF(ss, Agent_Real_Time.DateTimeLastStateChange, </pre>
<pre><span class="lnum">  78:  </span>                <span class="kwrd">CASE</span> </pre>
<pre class="alt"><span class="lnum">  79:  </span>                                <span class="kwrd">WHEN</span> (DATEDIFF(ss, Agent_Real_Time.DateTimeLastStateChange, (<span class="kwrd">SELECT</span> NowTime <span class="kwrd">from</span> Controller_Time (nolock))) &lt;= 0 ) </pre>
<pre><span class="lnum">  80:  </span>                                <span class="kwrd">THEN</span> Agent_Real_Time.DateTimeLastStateChange </pre>
<pre class="alt"><span class="lnum">  81:  </span>                                <span class="kwrd">ELSE</span>(<span class="kwrd">SELECT</span> NowTime <span class="kwrd">FROM</span> Controller_Time (nolock)) </pre>
<pre><span class="lnum">  82:  </span>                <span class="kwrd">END</span>), </pre>
<pre class="alt"><span class="lnum">  83:  </span>                <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum">  84:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.Routable = 1 </pre>
<pre class="alt"><span class="lnum">  85:  </span>                                <span class="kwrd">THEN</span> <span class="str">'Yes'</span> <span class="kwrd">ELSE</span> <span class="str">'No'</span> </pre>
<pre><span class="lnum">  86:  </span>                <span class="kwrd">END</span> RoutableText, </pre>
<pre class="alt"><span class="lnum">  87:  </span>                Agent_Real_Time.DateTimeLastModeChange, </pre>
<pre><span class="lnum">  88:  </span>                Agent_Real_Time.CallInProgress, </pre>
<pre class="alt"><span class="lnum">  89:  </span>                Agent_Real_Time.MaxTasks, </pre>
<pre><span class="lnum">  90:  </span>                <span class="kwrd">CASE</span> </pre>
<pre class="alt"><span class="lnum">  91:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.AvailableInMRD = 0 <span class="kwrd">THEN</span> <span class="str">'No'</span> </pre>
<pre><span class="lnum">  92:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.AvailableInMRD = 1 <span class="kwrd">THEN</span> <span class="str">'Yes_ICM'</span> </pre>
<pre class="alt"><span class="lnum">  93:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.AvailableInMRD = 2 <span class="kwrd">THEN</span> <span class="str">'Yes_APP'</span> </pre>
<pre><span class="lnum">  94:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'No'</span> </pre>
<pre class="alt"><span class="lnum">  95:  </span>                <span class="kwrd">END</span> AvailInMRDText, </pre>
<pre><span class="lnum">  96:  </span>                Agent_Real_Time.DateTimeTaskLevelChange, </pre>
<pre class="alt"><span class="lnum">  97:  </span>                Agent_Real_Time.RouterCallsQueueNow, </pre>
<pre><span class="lnum">  98:  </span>                Agent_Real_Time.RouterLongestCallQ </pre>
<pre class="alt"><span class="lnum">  99:  </span><span class="kwrd">FROM</span> </pre>
<pre><span class="lnum"> 100:  </span>                Agent (nolock), </pre>
<pre class="alt"><span class="lnum"> 101:  </span>                Person (nolock), </pre>
<pre><span class="lnum"> 102:  </span>                Media_Routing_Domain (nolock), </pre>
<pre class="alt"><span class="lnum"> 103:  </span>                Agent_Real_Time (nolock) <span class="kwrd">LEFT</span> <span class="kwrd">JOIN</span> Service (nolock) <span class="kwrd">ON</span> Agent_Real_Time.ServiceSkillTargetID = Service.SkillTargetID </pre>
<pre><span class="lnum"> 104:  </span>                <span class="kwrd">JOIN</span> Reason_Code <span class="kwrd">ON</span> Agent_Real_Time.ReasonCode = Reason_Code.ReasonCode,</pre>
<pre class="alt"><span class="lnum"> 105:  </span>                Skill_Group</pre>
<pre><span class="lnum"> 106:  </span><span class="kwrd">WHERE</span> ( Agent_Real_Time.SkillGroupSkillTargetID = Skill_Group.SkillTargetID) </pre>
<pre class="alt"><span class="lnum"> 107:  </span>                <span class="kwrd">and</span> Agent.PersonID=Person.PersonID </pre>
<pre><span class="lnum"> 108:  </span>                <span class="kwrd">and</span> Media_Routing_Domain.MRDomainID = Agent_Real_Time.MRDomainID </pre>
<pre class="alt"><span class="lnum"> 109:  </span>                <span class="kwrd">and</span> ( Agent.SkillTargetID = Agent_Real_Time.SkillTargetID ) </pre>
<pre><span class="lnum"> 110:  </span><span class="kwrd">UNION</span> <span class="kwrd">SELECT</span> </pre>
<pre class="alt"><span class="lnum"> 111:  </span>                Agent.EnterpriseName, </pre>
<pre><span class="lnum"> 112:  </span>                full_name=(Person.LastName + <span class="str">', '</span> + Person.FirstName) , </pre>
<pre class="alt"><span class="lnum"> 113:  </span>                <span class="kwrd">convert</span>(<span class="kwrd">varchar</span>,<span class="str">'Not Applicable'</span>), </pre>
<pre><span class="lnum"> 114:  </span>                Agent_Real_Time.SkillTargetID, </pre>
<pre class="alt"><span class="lnum"> 115:  </span>                Agent_Real_Time.DateTime, </pre>
<pre><span class="lnum"> 116:  </span>                Datepart(yy, Agent_Real_Time.DateTime) <span class="kwrd">as</span> <span class="kwrd">Year</span>, </pre>
<pre class="alt"><span class="lnum"> 117:  </span>                Datepart(mm, Agent_Real_Time.DateTime) <span class="kwrd">as</span> <span class="kwrd">Month</span>, </pre>
<pre><span class="lnum"> 118:  </span>                Datepart(ww, Agent_Real_Time.DateTime) <span class="kwrd">as</span> Week, </pre>
<pre class="alt"><span class="lnum"> 119:  </span>                Datepart(dy, Agent_Real_Time.DateTime) <span class="kwrd">as</span> DOY, </pre>
<pre><span class="lnum"> 120:  </span>                Datepart(dw, Agent_Real_Time.DateTime) <span class="kwrd">as</span> DOW, </pre>
<pre class="alt"><span class="lnum"> 121:  </span>                <span class="kwrd">CONVERT</span>(<span class="kwrd">char</span>(10),Agent_Real_Time.DateTime,101) <span class="kwrd">as</span> <span class="kwrd">DATE</span>, </pre>
<pre><span class="lnum"> 122:  </span>                Agent_Real_Time.SkillGroupSkillTargetID, </pre>
<pre class="alt"><span class="lnum"> 123:  </span>                ServiceName = Service.EnterpriseName, </pre>
<pre><span class="lnum"> 124:  </span>                Media=Media_Routing_Domain.EnterpriseName, </pre>
<pre class="alt"><span class="lnum"> 125:  </span>                <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum"> 126:  </span>                                Agent_Real_Time.AgentState </pre>
<pre class="alt"><span class="lnum"> 127:  </span>                                <span class="kwrd">WHEN</span> 0 <span class="kwrd">THEN</span> <span class="str">'Logged Out'</span> </pre>
<pre><span class="lnum"> 128:  </span>                                <span class="kwrd">WHEN</span> 1 <span class="kwrd">THEN</span> <span class="str">'Logged On'</span> </pre>
<pre class="alt"><span class="lnum"> 129:  </span>                                <span class="kwrd">WHEN</span> 2 <span class="kwrd">THEN</span> <span class="str">'Not Ready'</span> </pre>
<pre><span class="lnum"> 130:  </span>                                <span class="kwrd">WHEN</span> 3 <span class="kwrd">THEN</span> <span class="str">'Ready'</span> </pre>
<pre class="alt"><span class="lnum"> 131:  </span>                                <span class="kwrd">WHEN</span> 4 <span class="kwrd">THEN</span> <span class="str">'Talking'</span> </pre>
<pre><span class="lnum"> 132:  </span>                                <span class="kwrd">WHEN</span> 5 <span class="kwrd">THEN</span> <span class="str">'Work Not Ready'</span> </pre>
<pre class="alt"><span class="lnum"> 133:  </span>                                <span class="kwrd">WHEN</span> 6 <span class="kwrd">THEN</span> <span class="str">'Work Ready'</span> </pre>
<pre><span class="lnum"> 134:  </span>                                <span class="kwrd">WHEN</span> 7 <span class="kwrd">THEN</span> <span class="str">'Busy Other'</span> </pre>
<pre class="alt"><span class="lnum"> 135:  </span>                                <span class="kwrd">WHEN</span> 8 <span class="kwrd">THEN</span> <span class="str">'Reserved'</span>  </pre>
<pre><span class="lnum"> 136:  </span>                                <span class="kwrd">WHEN</span> 9 <span class="kwrd">THEN</span> <span class="str">'Unknown'</span> </pre>
<pre class="alt"><span class="lnum"> 137:  </span>                                <span class="kwrd">WHEN</span> 10 <span class="kwrd">THEN</span> <span class="str">'Hold'</span> </pre>
<pre><span class="lnum"> 138:  </span>                                <span class="kwrd">WHEN</span> 11 <span class="kwrd">THEN</span> <span class="str">'Active'</span>  </pre>
<pre class="alt"><span class="lnum"> 139:  </span>                                <span class="kwrd">WHEN</span> 12 <span class="kwrd">THEN</span> <span class="str">'Paused'</span> </pre>
<pre><span class="lnum"> 140:  </span>                                <span class="kwrd">WHEN</span> 13 <span class="kwrd">THEN</span> <span class="str">'Interrupted'</span> </pre>
<pre class="alt"><span class="lnum"> 141:  </span>                                <span class="kwrd">WHEN</span> 14 <span class="kwrd">THEN</span> <span class="str">'Not Active'</span> </pre>
<pre><span class="lnum"> 142:  </span>                                <span class="kwrd">ELSE</span> <span class="kwrd">CONVERT</span>(<span class="kwrd">VARCHAR</span>, Agent_Real_Time.AgentState) </pre>
<pre class="alt"><span class="lnum"> 143:  </span>                <span class="kwrd">END</span> AgentState, </pre>
<pre><span class="lnum"> 144:  </span>                <span class="kwrd">CASE</span> </pre>
<pre class="alt"><span class="lnum"> 145:  </span>                                Agent_Real_Time.PhoneType </pre>
<pre><span class="lnum"> 146:  </span>                                <span class="kwrd">When</span> 0 <span class="kwrd">THEN</span> <span class="str">'Not Mobile'</span></pre>
<pre class="alt"><span class="lnum"> 147:  </span>                                <span class="kwrd">WHEN</span> 1 <span class="kwrd">THEN</span> <span class="str">'Call By Call'</span> </pre>
<pre><span class="lnum"> 148:  </span>                                <span class="kwrd">WHEN</span> 2 <span class="kwrd">THEN</span> <span class="str">'Nailed Connection'</span> </pre>
<pre class="alt"><span class="lnum"> 149:  </span>                                <span class="kwrd">Else</span> <span class="str">'Not Applicable'</span> </pre>
<pre><span class="lnum"> 150:  </span>                <span class="kwrd">END</span> phonetypetext, </pre>
<pre class="alt"><span class="lnum"> 151:  </span>                remotephonenumber = Agent_Real_Time.RemotePhoneNumber, </pre>
<pre><span class="lnum"> 152:  </span>                ReasonCode = </pre>
<pre class="alt"><span class="lnum"> 153:  </span>                <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum"> 154:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.ReasonCode = 0 <span class="kwrd">THEN</span> <span class="str">'NONE'</span> </pre>
<pre class="alt"><span class="lnum"> 155:  </span>                                <span class="kwrd">ELSE</span> <span class="kwrd">CONVERT</span>(<span class="kwrd">VARCHAR</span>, Agent_Real_Time.ReasonCode) </pre>
<pre><span class="lnum"> 156:  </span>                <span class="kwrd">END</span> , </pre>
<pre class="alt"><span class="lnum"> 157:  </span>                Reason_Code.ReasonText,</pre>
<pre><span class="lnum"> 158:  </span>                Agent_Real_Time.Extension, </pre>
<pre class="alt"><span class="lnum"> 159:  </span>                Agent_Real_Time.DateTimeLastStateChange, </pre>
<pre><span class="lnum"> 160:  </span>                Agent_Real_Time.DateTimeLogin, </pre>
<pre class="alt"><span class="lnum"> 161:  </span>                <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum"> 162:  </span>                                <span class="kwrd">WHEN</span> RequestedSupervisorAssist = 1 <span class="kwrd">THEN</span> <span class="str">'Yes'</span> </pre>
<pre class="alt"><span class="lnum"> 163:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'No'</span> </pre>
<pre><span class="lnum"> 164:  </span>                <span class="kwrd">END</span> RequestedSupervisorAssist, </pre>
<pre class="alt"><span class="lnum"> 165:  </span>                <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum"> 166:  </span>                                Agent_Real_Time.Destination </pre>
<pre class="alt"><span class="lnum"> 167:  </span>                                <span class="kwrd">WHEN</span> 1 <span class="kwrd">THEN</span> <span class="str">'ACD'</span> </pre>
<pre><span class="lnum"> 168:  </span>                                <span class="kwrd">WHEN</span> 2 <span class="kwrd">THEN</span> <span class="str">'Direct'</span> </pre>
<pre class="alt"><span class="lnum"> 169:  </span>                                <span class="kwrd">WHEN</span> 3 <span class="kwrd">THEN</span> <span class="str">'Auto Out'</span> </pre>
<pre><span class="lnum"> 170:  </span>                                <span class="kwrd">WHEN</span> 4 <span class="kwrd">THEN</span> <span class="str">'Reserve'</span> </pre>
<pre class="alt"><span class="lnum"> 171:  </span>                                <span class="kwrd">WHEN</span> 5 <span class="kwrd">THEN</span> <span class="str">'Preview'</span> </pre>
<pre><span class="lnum"> 172:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'Not Applicable'</span> </pre>
<pre class="alt"><span class="lnum"> 173:  </span>                <span class="kwrd">END</span> Destination, </pre>
<pre><span class="lnum"> 174:  </span>                <span class="kwrd">CASE</span>  </pre>
<pre class="alt"><span class="lnum"> 175:  </span>                                Agent_Real_Time.Direction </pre>
<pre><span class="lnum"> 176:  </span>                                <span class="kwrd">WHEN</span> 1 <span class="kwrd">THEN</span> <span class="str">'In'</span> </pre>
<pre class="alt"><span class="lnum"> 177:  </span>                                <span class="kwrd">WHEN</span> 2 <span class="kwrd">THEN</span> <span class="str">'Out'</span> </pre>
<pre><span class="lnum"> 178:  </span>                                <span class="kwrd">WHEN</span> 3 <span class="kwrd">THEN</span> <span class="str">'Other'</span> </pre>
<pre class="alt"><span class="lnum"> 179:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'Not Applicable'</span> </pre>
<pre><span class="lnum"> 180:  </span>                <span class="kwrd">END</span> Direction, </pre>
<pre class="alt"><span class="lnum"> 181:  </span>                <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum"> 182:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.OnHold = 1 <span class="kwrd">THEN</span> <span class="str">'Yes'</span> </pre>
<pre class="alt"><span class="lnum"> 183:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'No'</span> </pre>
<pre><span class="lnum"> 184:  </span>                <span class="kwrd">END</span> OnHold, </pre>
<pre class="alt"><span class="lnum"> 185:  </span>                Agent_Real_Time.NetworkTargetID, </pre>
<pre><span class="lnum"> 186:  </span>                Agent_Real_Time.AgentStatus, </pre>
<pre class="alt"><span class="lnum"> 187:  </span>                Agent_Real_Time.CustomerPhoneNumber, </pre>
<pre><span class="lnum"> 188:  </span>                Agent_Real_Time.CustomerAccountNumber, </pre>
<pre class="alt"><span class="lnum"> 189:  </span>                Agent_Real_Time.CampaignID, </pre>
<pre><span class="lnum"> 190:  </span>                Agent_Real_Time.QueryRuleID, </pre>
<pre class="alt"><span class="lnum"> 191:  </span>                Duration=DATEDIFF(ss, Agent_Real_Time.DateTimeLastStateChange, </pre>
<pre><span class="lnum"> 192:  </span>                <span class="kwrd">CASE</span> </pre>
<pre class="alt"><span class="lnum"> 193:  </span>                                <span class="kwrd">WHEN</span> (DATEDIFF(ss, Agent_Real_Time.DateTimeLastStateChange, </pre>
<pre><span class="lnum"> 194:  </span>                                (<span class="kwrd">SELECT</span> NowTime <span class="kwrd">from</span> Controller_Time (nolock)))  &lt;= 0 ) </pre>
<pre class="alt"><span class="lnum"> 195:  </span>                                <span class="kwrd">THEN</span> Agent_Real_Time.DateTimeLastStateChange    </pre>
<pre><span class="lnum"> 196:  </span>                                <span class="kwrd">ELSE</span> (<span class="kwrd">SELECT</span> NowTime <span class="kwrd">FROM</span> Controller_Time (nolock)) </pre>
<pre class="alt"><span class="lnum"> 197:  </span>                <span class="kwrd">END</span>), </pre>
<pre><span class="lnum"> 198:  </span>                <span class="kwrd">CASE</span> </pre>
<pre class="alt"><span class="lnum"> 199:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.Routable = 1 <span class="kwrd">THEN</span> <span class="str">'Yes'</span> </pre>
<pre><span class="lnum"> 200:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'No'</span> </pre>
<pre class="alt"><span class="lnum"> 201:  </span>                <span class="kwrd">END</span> RoutableText , </pre>
<pre><span class="lnum"> 202:  </span>                Agent_Real_Time.DateTimeLastModeChange, </pre>
<pre class="alt"><span class="lnum"> 203:  </span>                Agent_Real_Time.CallInProgress, </pre>
<pre><span class="lnum"> 204:  </span>                Agent_Real_Time.MaxTasks, </pre>
<pre class="alt"><span class="lnum"> 205:  </span>                <span class="kwrd">CASE</span> </pre>
<pre><span class="lnum"> 206:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.AvailableInMRD = 0 <span class="kwrd">THEN</span> <span class="str">'No'</span> </pre>
<pre class="alt"><span class="lnum"> 207:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.AvailableInMRD = 1 <span class="kwrd">THEN</span> <span class="str">'Yes_ICM'</span> </pre>
<pre><span class="lnum"> 208:  </span>                                <span class="kwrd">WHEN</span> Agent_Real_Time.AvailableInMRD = 2 <span class="kwrd">THEN</span> <span class="str">'Yes_APP'</span> </pre>
<pre class="alt"><span class="lnum"> 209:  </span>                                <span class="kwrd">ELSE</span> <span class="str">'No'</span> </pre>
<pre><span class="lnum"> 210:  </span>                <span class="kwrd">END</span> AvailInMRDText, </pre>
<pre class="alt"><span class="lnum"> 211:  </span>                Agent_Real_Time.DateTimeTaskLevelChange, </pre>
<pre><span class="lnum"> 212:  </span>                Agent_Real_Time.RouterCallsQueueNow, </pre>
<pre class="alt"><span class="lnum"> 213:  </span>                Agent_Real_Time.RouterLongestCallQ </pre>
<pre><span class="lnum"> 214:  </span>                <span class="kwrd">FROM</span>   </pre>
<pre class="alt"><span class="lnum"> 215:  </span>                                Agent (nolock), </pre>
<pre><span class="lnum"> 216:  </span>                                Person (nolock), </pre>
<pre class="alt"><span class="lnum"> 217:  </span>                                Media_Routing_Domain (nolock), </pre>
<pre><span class="lnum"> 218:  </span>                                Agent_Real_Time (nolock) <span class="kwrd">LEFT</span> <span class="kwrd">JOIN</span> Service (nolock) <span class="kwrd">ON</span> Agent_Real_Time.ServiceSkillTargetID = Service.SkillTargetID</pre>
<pre class="alt"><span class="lnum"> 219:  </span>                                <span class="kwrd">JOIN</span> Reason_Code <span class="kwrd">ON</span> Agent_Real_Time.ReasonCode = Reason_Code.ReasonCode</pre>
<pre><span class="lnum"> 220:  </span>                <span class="kwrd">WHERE</span> </pre>
<pre class="alt"><span class="lnum"> 221:  </span>                                ((Agent_Real_Time.SkillGroupSkillTargetID = 0) <span class="kwrd">OR</span> (Agent_Real_Time.SkillGroupSkillTargetID <span class="kwrd">IS</span> <span class="kwrd">NULL</span>)) </pre>
<pre><span class="lnum"> 222:  </span>                                <span class="kwrd">and</span> Agent.PersonID=Person.PersonID</pre>
<pre class="alt"><span class="lnum"> 223:  </span>                                <span class="kwrd">and</span> Media_Routing_Domain.MRDomainID = Agent_Real_Time.MRDomainID </pre>
<pre><span class="lnum"> 224:  </span>                                <span class="kwrd">and</span> ( Agent.SkillTargetID = Agent_Real_Time.SkillTargetID )</pre>
</div>
<p>
<style type="text/css">
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
</p>
<p>Note line 46 and 104 where the join is made to retrieve the reason text.&#160; Also note that you need to duplicate these lines in the Union Select statement.</p>
<p>Finally, create a new report definition, create a new report based off the definition, and test.&#160; This posts assumes that you know at least the very basics around CUIC.&#160; It doesn’t hurt to know some SQL, personally I know enough to be dangerous, but touch it so seldom that I’m no expert.</p>
<p>Hope this helps others out there as this is a pretty common report and a lot of customer ask for it.</p>
<p>~david</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2012/03/12/cisco-cuic-real-time-agent-report-with-not-ready-reason-code/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How many Cisco CTI OS agents are current logged in?</title>
		<link>http://dmacias.org/2012/02/01/how-many-cisco-cti-os-agents-are-current-logged-in/</link>
		<comments>http://dmacias.org/2012/02/01/how-many-cisco-cti-os-agents-are-current-logged-in/#comments</comments>
		<pubDate>Thu, 02 Feb 2012 01:24:50 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Cisco ICM]]></category>
		<category><![CDATA[ctios]]></category>

		<guid isPermaLink="false">http://dmacias.org/?p=494</guid>
		<description><![CDATA[I’ve seen this question come up a few times in the Cisco Support Community.&#160; Figured I would post something about it here.&#160; The question is to find out how many agents are currently logged to CTI OS.&#160; The following will give you the current number of logged in agents and if you leave it running [...]]]></description>
			<content:encoded><![CDATA[<p>I’ve seen this question come up a few times in the Cisco Support Community.&#160; Figured I would post something about it here.&#160; The question is to find out how many agents are currently logged to CTI OS.&#160; The following will give you the current number of logged in agents and if you leave it running for a long period of time it will tell you how many agents logged in by average, minimum, and maximum number of logged in agents.</p>
<p>- All Programs &gt; Administrator Tools &gt; Performance   <br />- Click on New Counter Set    <br />- Right click on the counter screen and click on Add Counters…    <br />- Select the following counter below</p>
<p><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="clip_image002[4]" border="0" alt="clip_image002[4]" src="http://dmacias.org/wp-content/uploads/2012/02/clip_image00241.jpg" width="244" height="241" /></p>
<p>- You will see the counter increase/decrease as agents log in and out.</p>
<p><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="clip_image002" border="0" alt="clip_image002" src="http://dmacias.org/wp-content/uploads/2012/02/clip_image0021.jpg" width="644" height="456" /></p>
<p>~dmacias</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2012/02/01/how-many-cisco-cti-os-agents-are-current-logged-in/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>New Years Resolutions and Data Visualization</title>
		<link>http://dmacias.org/2011/12/04/new-years-resolutions-and-data-visualization/</link>
		<comments>http://dmacias.org/2011/12/04/new-years-resolutions-and-data-visualization/#comments</comments>
		<pubDate>Sun, 04 Dec 2011 22:07:22 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Writings]]></category>

		<guid isPermaLink="false">http://dmacias.org/2011/12/04/new-years-resolutions-and-data-visualization/</guid>
		<description><![CDATA[At the end of last year (December 2010) I set out to change a few things.&#160; The biggest one being to try and burn 10,000 calories a month through exercise.&#160; The first few months I kept track of my calorie expenditure base on a heart monitor, when my heart monitor met an untimely death I [...]]]></description>
			<content:encoded><![CDATA[<p>At the end of last year (December 2010) I set out to change a few things.&#160; The biggest one being to try and burn 10,000 calories a month through exercise.&#160; The first few months I kept track of my calorie expenditure base on a heart monitor, when my heart monitor met an untimely death I switched to an Android app call <a href="http://www.worksmartlabs.com/cardiotrainer/about.php">CardioTrainer</a>. I highly recommend this app for anyone else who wants to keep track of their workouts.</p>
<p>While I was only able to accomplish this 6 times, I have burned over 100,000 calories so far and lost about 10 pounds.&#160; I will continue working towards 10,000 a month in 2012.&#160; So, now I have a year of data and I’ve been looking to play around with <a href="http://code.google.com/apis/chart/interactive/docs/index.html">Google’s Chart Tools</a> and figure this would be the combination.&#160; Here’s my first stab at visualizing the data I’ve collected so far.</p>
<p>&#160;</p>
<p><script src="https://docs.google.com/spreadsheet/gpub?url=http%3A%2F%2Ftbaoebshgeq225lhq2bam0m0a5mf6u0b-ss-opensocial.googleusercontent.com%2Fgadgets%2Fifr%3Fup_title%3DWorkout%2520Data%26up_scale%3Dfixed%26up_values_suffix%26up_annotations_width%3D25%26up_display_zoom_buttons%3D1%26up_display_exact_values%3D1%26up_display_annotations_filter%3D1%26up_display_legend_inNewline%3D1%26up__table_query_url%3Dhttps%253A%252F%252Fdocs.google.com%252Fspreadsheet%252Ftq%253Frange%253DA%25253AC%2526key%253D0AlWL5v9vYcAwdFR5UWdfSjM0c1gweUVMX3dBV0JiY0E%2526gid%253D0%2526pub%253D1%26url%3Dhttp%253A%252F%252Fwww.google.com%252Fig%252Fmodules%252Ftime-series-line.xml%26spreadsheets%3Dspreadsheets&#038;height=320&#038;width=600"></script></p>
<p>~david</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2011/12/04/new-years-resolutions-and-data-visualization/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Cisco CRM Adapter with Firefox</title>
		<link>http://dmacias.org/2011/09/10/cisco-crm-adapter-with-firefox/</link>
		<comments>http://dmacias.org/2011/09/10/cisco-crm-adapter-with-firefox/#comments</comments>
		<pubDate>Sat, 10 Sep 2011 11:34:43 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Cisco CRM Adapter]]></category>
		<category><![CDATA[Salesforce.com]]></category>
		<category><![CDATA[SFDC]]></category>

		<guid isPermaLink="false">http://dmacias.org/2011/09/10/cisco-crm-adapter-with-firefox/</guid>
		<description><![CDATA[I will assume you have the server connected and working properly, this post focuses solely on getting the CRM adapter working with Firefox 3.x, 6.x.&#160; The version I’m working with is Cisco_Unified_CRM_Connector_7.52, which allows you to install the server or client.&#160; This is Cisco’s latest version and upon install it includes Salesforce.com Adapter 3.00.&#160; Install [...]]]></description>
			<content:encoded><![CDATA[<p>I will assume you have the server connected and working properly, this post focuses solely on getting the CRM adapter working with Firefox 3.x, 6.x.&#160; The version I’m working with is Cisco_Unified_CRM_Connector_7.52, which allows you to install the server or client.&#160; This is Cisco’s latest version and upon install it includes Salesforce.com Adapter 3.00.&#160; Install the adapter, including the Firefox extension and perform the following steps:</p>
<ul>
<li>Download the <a href="http://developerforce_shared.s3.amazonaws.com/media/CTI Toolkit/CTI-3.01/demo_3_01_setup.exe">Demo Adapter 3.01</a>.&#160; This includes the Salesforce.com Adapter 3.01.</li>
<li>Run through setup and install it in a different directory.&#160; Ensure you install the Firefox extension.&#160; Cisco’s in C:\Program Files\Cisco\CRM Connector\Salesforce.com Adapter\ and Salesforce in C:\Program Files\Salesforce.com\Demo Adapter 3.01.</li>
<li>Go to the Demo Adapter 3.01 folder and register the SFDCFirefoxConnector.dll and SFDCFirefoxConnectorPS.dll.</li>
<ul>
<li>You can register them by double clicking on the file and opening them with C:\Windows\System32\regsvr32.exe</li>
</ul>
<li>Restart Firefox.</li>
</ul>
<p>Firefox should now be working with your Salesforce.com instance.&#160; Please note that you now have two adapters and you must be running Cisco’s version 3.00 in order for this to work.&#160; I’m assuming someone at Cisco didn’t package the right DLL and or the right Firefox extension (which is included in the Demo Adapter 3.01 folder sfdcffextension.xpi).</p>
<p>~dmacias</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2011/09/10/cisco-crm-adapter-with-firefox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android Development: Clickable TextView Relative Layout Using Tables</title>
		<link>http://dmacias.org/2011/02/23/android-development-clickable-textview-relative-layout-using-tables/</link>
		<comments>http://dmacias.org/2011/02/23/android-development-clickable-textview-relative-layout-using-tables/#comments</comments>
		<pubDate>Wed, 23 Feb 2011 15:07:54 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Google Android]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dmacias.org/2011/02/23/android-development-clickable-textview-relative-layout-using-tables/</guid>
		<description><![CDATA[I’ve been playing around with the Google Android SDK, since there are a couple of mobile application ideas I’ve been tossing around.&#160; However, since it’s been longer than 10 years since I’ve done any real Java development I’m taking it pretty slow and just getting used to the tools available for Android development. The very [...]]]></description>
			<content:encoded><![CDATA[<p>I’ve been playing around with the Google Android SDK, since there are a couple of mobile application ideas I’ve been tossing around.&#160; However, since it’s been longer than 10 years since I’ve done any real Java development I’m taking it pretty slow and just getting used to the tools available for Android development.</p>
<p>The very first thing is to go through the <a href="http://developer.android.com/resources/browser.html?tag=tutorial" target="_blank">tutorials</a> that Google has put together, they will give you a very quick understanding on how Android is put together and what all the pieces do in order to construct an application.</p>
<p>Next, appearance is everything, so you need to get familiar with layouts and <a href="http://developer.android.com/resources/browser.html?tag=tutorial" target="_blank">DroidDraw</a> is the best tool available for understanding how things align.&#160; Use the DroidDraw generated code as a template and play around accordingly.</p>
<p>Finally, play around.</p>
<p>The first application I wanted to create was a gym schedule for my local gym and I will be updating the world as I move along.&#160; The first thing I’ve created is the layout and basic functionality of the application.&#160; This will consist of a couple of rows with the pertinent information as well as a clickable text area which will provide more information about the class.&#160; Notice that all data is static as this is just a framework for what I hope the final application to look like.</p>
<p>Here’s the final product as of this point:</p>
<p><a href="http://dmacias.org/wp-content/uploads/2011/02/image.png"><img style="background-image: none; border-right-width: 0px; margin: 0px auto 1px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://dmacias.org/wp-content/uploads/2011/02/image_thumb.png" width="284" height="484" /></a></p>
<p>The breakdown of the code is as follows:</p>
<p>colors.xml</p>
<div id="codeSnippetWrapper">
<div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet">
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum1">   1:</span> &lt;<span style="color: #008000">;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum2">   2:</span> &lt;<span style="color: #008000">;resources&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum3">   3:</span>         &lt;<span style="color: #008000">;color name=&quot;grey&quot;&gt;#C0C0C0&lt;/color&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum4">   4:</span>         &lt;<span style="color: #008000">;color name=&quot;black&quot;&gt;#000000&lt;/color&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum5">   5:</span>         &lt;<span style="color: #008000">;color name=&quot;light_grey&quot;&gt;#A8A8A8&lt;/color&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum6">   6:</span> &lt;<span style="color: #008000">;/resources&gt;</span></pre>
<p><!--CRLF--></div>
</div>
<style type="text/css">
<p>.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p>main.xml</p>
<div id="codeSnippetWrapper">
<div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet">
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum1">   1:</span> &lt;<span style="color: #008000">;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum2">   2:</span> &lt;<span style="color: #008000">;TableLayout xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum3">   3:</span>     android:layout_width=<span style="color: #006080">&quot;fill_parent&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum4">   4:</span>     android:layout_height=<span style="color: #006080">&quot;fill_parent&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum5">   5:</span>     android:stretchColumns=<span style="color: #006080">&quot;*&quot;</span>&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum6">   6:</span> <span style="color: #008000">    &lt;TableRow android:background=&quot;@color/grey&quot; &gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum7">   7:</span>         &lt;<span style="color: #008000">;TextView</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum8">   8:</span>             android:textStyle=<span style="color: #006080">&quot;bold&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum9">   9:</span>             android:text=<span style="color: #006080">&quot;Monday&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum10">  10:</span>             android:padding=<span style="color: #006080">&quot;3dip&quot;</span> </pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum11">  11:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum12">  12:</span>             android:textSize=<span style="color: #006080">&quot;18sp&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum13">  13:</span>             /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum14">  14:</span> <span style="color: #008000">    &lt;/TableRow&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum15">  15:</span>     &lt;<span style="color: #008000">;TableRow android:background=&quot;@color/light_grey&quot;&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum16">  16:</span>         &lt;<span style="color: #008000">;TextView android:text=&quot;Time&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum17">  17:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> android:textStyle=<span style="color: #006080">&quot;bold&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum18">  18:</span> <span style="color: #008000">        &lt;TextView android:text=&quot;Class&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum19">  19:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> android:textStyle=<span style="color: #006080">&quot;bold&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum20">  20:</span> <span style="color: #008000">        &lt;TextView android:text=&quot;Studio&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum21">  21:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> android:textStyle=<span style="color: #006080">&quot;bold&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum22">  22:</span> <span style="color: #008000">        &lt;TextView android:text=&quot;Instructor&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum23">  23:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> android:textStyle=<span style="color: #006080">&quot;bold&quot;</span>/&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum24">  24:</span> <span style="color: #008000">    &lt;/TableRow&gt;    </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum25">  25:</span>     &lt;<span style="color: #008000">;TableRow android:background=&quot;@color/grey&quot;&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum26">  26:</span>         &lt;<span style="color: #008000">;TextView android:id=&quot;@+id/Time&quot; android:text=&quot;6:00 AM&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum27">  27:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum28">  28:</span> <span style="color: #008000">        &lt;TextView android:id=&quot;@+id/Class&quot; android:text=&quot;Cycle&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum29">  29:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum30">  30:</span> <span style="color: #008000">        &lt;TextView android:id=&quot;@+id/Studio&quot; android:text=&quot;C&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum31">  31:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum32">  32:</span> <span style="color: #008000">        &lt;TextView android:id=&quot;@+id/Instructor&quot; android:text=&quot;Jamie&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum33">  33:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span>/&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum34">  34:</span> <span style="color: #008000">    &lt;/TableRow&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum35">  35:</span>     &lt;<span style="color: #008000">;TableRow android:background=&quot;@color/light_grey&quot; &gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum36">  36:</span>         &lt;<span style="color: #008000">;TextView /&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum37">  37:</span>         &lt;<span style="color: #008000">;TextView /&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum38">  38:</span>         &lt;<span style="color: #008000">;TextView /&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum39">  39:</span>         &lt;<span style="color: #008000">;TextView android:id=&quot;@+id/MoreInfo&quot; android:text=&quot;More Info &gt;&quot; android:padding=&quot;3dip&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum40">  40:</span>         android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> android:onClick=<span style="color: #006080">&quot;onClick&quot;</span> android:clickable=<span style="color: #006080">&quot;true&quot;</span>/&gt;<span style="color: #008000">; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum41">  41:</span> <span style="color: #008000">    &lt;/TableRow&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum42">  42:</span>         &lt;<span style="color: #008000">;TableRow android:background=&quot;@color/grey&quot;&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum43">  43:</span>         &lt;<span style="color: #008000">;TextView android:id=&quot;@+id/Time&quot; android:text=&quot;7:00 PM&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum44">  44:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum45">  45:</span> <span style="color: #008000">        &lt;TextView android:id=&quot;@+id/Class&quot; android:text=&quot;Fundamentals of Yoga&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum46">  46:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum47">  47:</span> <span style="color: #008000">        &lt;TextView android:id=&quot;@+id/Studio&quot; android:text=&quot;GF&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum48">  48:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> /&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum49">  49:</span> <span style="color: #008000">        &lt;TextView android:id=&quot;@+id/Instructor&quot; android:text=&quot;Eleanor&quot; android:padding=&quot;3dip&quot; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum50">  50:</span>             android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span>/&gt;<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum51">  51:</span> <span style="color: #008000">    &lt;/TableRow&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum52">  52:</span>     &lt;<span style="color: #008000">;TableRow android:background=&quot;@color/light_grey&quot; &gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum53">  53:</span>         &lt;<span style="color: #008000">;TextView /&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum54">  54:</span>         &lt;<span style="color: #008000">;TextView /&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum55">  55:</span>         &lt;<span style="color: #008000">;TextView /&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum56">  56:</span>         &lt;<span style="color: #008000">;TextView android:id=&quot;@+id/MoreInfo&quot; android:text=&quot;More Info &gt;&quot; android:padding=&quot;3dip&quot;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum57">  57:</span>         android:textColor=<span style="color: #006080">&quot;@color/black&quot;</span> android:onClick=<span style="color: #006080">&quot;onClick&quot;</span> android:clickable=<span style="color: #006080">&quot;true&quot;</span>/&gt;<span style="color: #008000">; </span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum58">  58:</span> <span style="color: #008000">    &lt;/TableRow&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum59">  59:</span> &lt;/TableLayout&gt;</pre>
<p><!--CRLF--></div>
</div>
<style type="text/css">
<p>.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p>.java file:</p>
<div id="codeSnippetWrapper">
<div style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px" id="codeSnippet">
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum1">   1:</span> package com.example.RelativeLayout<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum2">   2:</span> <span style="color: #008000"></span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum3">   3:</span> <span style="color: #008000">import android.app.Activity;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum4">   4:</span> import android.os.Bundle<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum5">   5:</span> <span style="color: #008000">import android.view.View;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum6">   6:</span> import android.widget.Toast<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum7">   7:</span> <span style="color: #008000"></span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum8">   8:</span> <span style="color: #008000">public class RelativeLayout extends Activity {</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum9">   9:</span>     /** Called when the activity is first created. */</pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum10">  10:</span>     @Override</pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum11">  11:</span>     public void onCreate(Bundle savedInstanceState) {</pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum12">  12:</span>         super.onCreate(savedInstanceState)<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum13">  13:</span> <span style="color: #008000">        setContentView(R.layout.main);</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum14">  14:</span>     }</pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum15">  15:</span>     public void onClick(View v){</pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum16">  16:</span>         Toast toast = Toast.makeText(getApplicationContext(), </pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum17">  17:</span> <span style="color: #006080">&quot;Cycle/Spinning – Stationary bike cardio workout in a </pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum18">  18:</span> group setting. Water bottles and a towel required </pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum19">  19:</span> for attendance.&quot;</span>, Toast.LENGTH_LONG)<span style="color: #008000">;</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum20">  20:</span> <span style="color: #008000">        toast.show();</span></pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum21">  21:</span>     }</pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: #f4f4f4; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; color: black; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum22">  22:</span> }</pre>
<p><!--CRLF--></p>
<pre style="border-bottom-style: none; text-align: left; padding-bottom: 0px; line-height: 12pt; border-right-style: none; background-color: white; margin: 0em; padding-left: 0px; width: 100%; padding-right: 0px; font-family: &#39;Courier New&#39;, courier, monospace; direction: ltr; border-top-style: none; font-size: 8pt; border-left-style: none; overflow: visible; padding-top: 0px"><span style="color: #606060" id="lnum23">  23:</span>&#160; </pre>
<p><!--CRLF--></div>
</div>
<p>~david</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2011/02/23/android-development-clickable-textview-relative-layout-using-tables/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Playing around with Twitter API using Tweepy</title>
		<link>http://dmacias.org/2010/12/31/playing-around-with-twitter-api-using-tweepy/</link>
		<comments>http://dmacias.org/2010/12/31/playing-around-with-twitter-api-using-tweepy/#comments</comments>
		<pubDate>Fri, 31 Dec 2010 07:19:39 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Tweepy]]></category>
		<category><![CDATA[Twitter API]]></category>

		<guid isPermaLink="false">http://dmacias.org/2010/12/31/playing-around-with-twitter-api-using-tweepy/</guid>
		<description><![CDATA[Yes, this is the kind of stuff I find myself doing when I’m bored.&#160; Just a quick tutorial on using the Twitter python library called Tweepy.&#160; Examples include authentication, print your statuses, and print your mentions. First, you need to authenticate using OAuth as simple authentication has been disabled by Twitter.&#160; I will not repeat [...]]]></description>
			<content:encoded><![CDATA[<p>Yes, this is the kind of stuff I find myself doing when I’m bored.&#160; Just a quick tutorial on using the Twitter python library called Tweepy.&#160; Examples include authentication, print your statuses, and print your mentions.</p>
<p>First, you need to authenticate using OAuth as simple authentication has been disabled by Twitter.&#160; I will not repeat what has already been done, <a href="http://jeffmiller.github.com/2010/05/31/twitter-from-the-command-line-in-python-using-oauth">so this is the best way to do it</a>.&#160; If you have no problems with that example, then at the end you will have a simple python script which allows you to update your status via the command line.&#160; However, the most important piece is the authentication:</p>
<div class="csharpcode">
<pre class="alt"><span class="lnum">   1:  </span>#!/usr/bin/env python</pre>
<pre><span class="lnum">   2:  </span>&#160;</pre>
<pre class="alt"><span class="lnum">   3:  </span>import sys</pre>
<pre><span class="lnum">   4:  </span>import tweepy</pre>
<pre class="alt"><span class="lnum">   5:  </span>&#160;</pre>
<pre><span class="lnum">   6:  </span>CONSUMER_KEY = <span class="str">'Your stuff'</span></pre>
<pre class="alt"><span class="lnum">   7:  </span>CONSUMER_SECRET = <span class="str">'Your stuff'</span></pre>
<pre><span class="lnum">   8:  </span>ACCESS_KEY = <span class="str">'Your stuff'</span></pre>
<pre class="alt"><span class="lnum">   9:  </span>ACCESS_SECRET = <span class="str">'Your stuff'</span></pre>
<pre><span class="lnum">  10:  </span>&#160;</pre>
<pre class="alt"><span class="lnum">  11:  </span>auth = tweepy.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)</pre>
<pre><span class="lnum">  12:  </span>auth.set_access_token(ACCESS_KEY, ACCESS_SECRET)</pre>
<pre class="alt"><span class="lnum">  13:  </span>api = tweepy.API(auth)</pre>
</div>
<style type="text/css">
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p>This will allow you to authenticate against Twitter and be able to work with the API.&#160; Now you can add to your python script the code below.</p>
<p>How about printing your status updates?</p>
<div class="csharpcode">
<pre class="alt"><span class="lnum">   1:  </span>statuses = tweepy.Cursor(api.user_timeline).items()</pre>
<pre><span class="lnum">   2:  </span>&#160;</pre>
<pre class="alt"><span class="lnum">   3:  </span><span class="kwrd">for</span> status <span class="kwrd">in</span> statuses:</pre>
<pre><span class="lnum">   4:  </span>        print <span class="str">&quot; &quot;</span></pre>
<pre class="alt"><span class="lnum">   5:  </span>        print status.text</pre>
</div>
<p>
<style type="text/css">
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
</p>
<p>How about printing your mentions?</p>
<div class="csharpcode">
<pre class="alt"><span class="lnum">   1:  </span>mymentions= tweepy.Cursor(api.mentions).items()</pre>
<pre><span class="lnum">   2:  </span>&#160;</pre>
<pre class="alt"><span class="lnum">   3:  </span><span class="kwrd">for</span> status <span class="kwrd">in</span> mymentions:</pre>
<pre><span class="lnum">   4:  </span>        print <span class="str">&quot; &quot;</span></pre>
<pre class="alt"><span class="lnum">   5:  </span>        print status.text</pre>
</div>
<style type="text/css">
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p>&#160;</p>
<p>The <a href="http://joshthecoder.github.com/tweepy/docs/api.html?highlight=page">Tweepy API reference</a> has a ton of great information.&#160; As well as the <a href="http://apiwiki.twitter.com/w/page/22554679/Twitter-API-Documentation">Twitter API wiki</a>.</p>
<p>~david</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2010/12/31/playing-around-with-twitter-api-using-tweepy/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>mRemote and Cisco&#8217;s AnyConnect Client Issues</title>
		<link>http://dmacias.org/2010/12/08/mremote-and-ciscos-anyconnect-client-issues/</link>
		<comments>http://dmacias.org/2010/12/08/mremote-and-ciscos-anyconnect-client-issues/#comments</comments>
		<pubDate>Thu, 09 Dec 2010 00:11:21 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Cisco]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[cisco AnyConnect]]></category>
		<category><![CDATA[mRemote]]></category>
		<category><![CDATA[mRemoteNG]]></category>

		<guid isPermaLink="false">http://dmacias.org/2010/12/08/mremote-and-ciscos-anyconnect-client-issues/</guid>
		<description><![CDATA[I love mRemote.&#160; Makes keeping track of all the different connections (RDP, VNC, SSH, etc.) a breeze.&#160; However, I’ve recently noticed that after I installed Cisco’s AnyConnect client I could no longer open my existing connections or create new connections.&#160; Upon startup I would receive the following window: What I ended up having to do [...]]]></description>
			<content:encoded><![CDATA[<p>I love mRemote.&#160; Makes keeping track of all the different connections (RDP, VNC, SSH, etc.) a breeze.&#160; However, I’ve recently noticed that after I installed Cisco’s AnyConnect client I could no longer open my existing connections or create new connections.&#160; Upon startup I would receive the following window:</p>
<p><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto 1px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="mRemoteSecurityPassword" border="0" alt="mRemoteSecurityPassword" src="http://dmacias.org/wp-content/uploads/2010/12/mRemoteSecurityPassword1.jpg" width="357" height="232" /></p>
<p>What I ended up having to do is remove AnyConnect and then disable FIPS encryption following this link <a title="http://support.microsoft.com/kb/811770" href="http://support.microsoft.com/kb/811770">http://support.microsoft.com/kb/811770</a>.</p>
<p><img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px auto 1px; padding-left: 0px; padding-right: 0px; display: block; float: none; border-top: 0px; border-right: 0px; padding-top: 0px" title="WindowsPolicy" border="0" alt="WindowsPolicy" src="http://dmacias.org/wp-content/uploads/2010/12/WindowsPolicy1.png" width="450" height="96" /></p>
<p>Works like a charm now.&#160; More than likely you don’t have to remove AnyConnect, however I don’t use it that much and rather just remove it all together.</p>
<p>~david</p>
<p>PS: The mRemote project is dead at version 1.5, there’s a fork out there called mRemoteNG which I’m trying out check it out here <a title="http://www.mremoteng.org/" href="http://www.mremoteng.org/">http://www.mremoteng.org/</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2010/12/08/mremote-and-ciscos-anyconnect-client-issues/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Create Hyperlinks to Worksheets with Excel VBA</title>
		<link>http://dmacias.org/2010/11/05/create-hyperlinks-to-worksheets-with-excel-vba/</link>
		<comments>http://dmacias.org/2010/11/05/create-hyperlinks-to-worksheets-with-excel-vba/#comments</comments>
		<pubDate>Fri, 05 Nov 2010 21:47:43 +0000</pubDate>
		<dc:creator>dmacias</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Microsoft Excel]]></category>
		<category><![CDATA[VBA]]></category>

		<guid isPermaLink="false">http://dmacias.org/2010/11/05/create-hyperlinks-to-worksheets-with-excel-vba/</guid>
		<description><![CDATA[This took me a couple of hours to get working, which means that one of two things happened.&#160; I am very rusty in my VB or nothing I found online made sense.&#160; I’m going with a little bit of the former and a lot of the latter. The problem I was facing is that I [...]]]></description>
			<content:encoded><![CDATA[<p>This took me a couple of hours to get working, which means that one of two things happened.&nbsp; I am very rusty in my VB or nothing I found online made sense.&nbsp; I’m going with a little bit of the former and a lot of the latter.</p>
<p>The problem I was facing is that I wanted to create an Excel dashboard which linked worksheets in the file.&nbsp; I wanted to do this dynamically using VBA in order to be able to get a snapshot of the whole workbook without having to go sheet by sheet.</p>
<p>The final code looks like this:</p>
<div class="csharpcode">
<div class="csharpcode">
<pre class="alt"><span class="lnum">   1:  </span>LinkToSheet = <span class="str">"'"</span> &amp; Sheets(i).Name &amp; <span class="str">"'!A1"</span></pre>
<pre><span class="lnum">   2:  </span>NewSheet.Hyperlinks.Add Anchor:=NewSheet.Cells(10 + c, 6), Address:=<span class="str">""</span>, </pre>
<pre class="alt"><span class="lnum">   3:  </span>SubAddress:=LinkToSheet, ScreenTip:=<span class="str">""</span>, TextToDisplay:=<span class="str">""</span></pre>
</div>
<style type="text/css">.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }
</style>
<pre><span class="str">&nbsp;</pre>
<p></span></div>
<style type="text/css">
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p>Now to break it down a bit for those of us who need a little help with VB.&nbsp; This part of the code dictates the worksheet where the hyperlink will go, in this case I have a variable called NewSheet:</p>
<div class="csharpcode">
<pre class="alt"><span class="lnum">   1:  </span>NewSheet.Hyperlinks.Add</pre>
</div>
<div class="csharpcode">&nbsp;</div>
<p>The Anchor property is the location of where to put the hyperlink.&nbsp; In my case it’s dynamic, but for most people it might be a static location (e.g. F2) like this:</p>
<div class="csharpcode">&nbsp;</div>
<div class="csharpcode">
<pre class="alt"><span class="lnum">   1:  </span>NewSheet.Hyperlinks.Add Anchor:=F2</pre>
</div>
<div class="csharpcode">&nbsp;</div>
<style type="text/css">
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
<p>The Address property needs to be blank if you’re linking to other worksheets, you use this if you’re linking to other files or URLs.&nbsp; The LinkToSheet variable is used because some of the worksheet names I use have spaces, so I need to be able to format my worksheet as ‘WorkSheet Name’!A1.&nbsp; Finally, the last two properties are more adornments than anything else in case you have to have a hover tip or display different text than the name of the worksheet.</p>
<p>~david</p>
]]></content:encoded>
			<wfw:commentRss>http://dmacias.org/2010/11/05/create-hyperlinks-to-worksheets-with-excel-vba/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

