<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Redsouljaz's Blog</title>
	<atom:link href="http://redsouljaz.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://redsouljaz.wordpress.com</link>
	<description>Welcome to my Blog, In my blog I'm going to write artice about everything that I'm doing, I like, I dislike and anything that I feel like to share it. So Enjoy it</description>
	<lastBuildDate>Thu, 31 Mar 2011 17:11:41 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='redsouljaz.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Redsouljaz's Blog</title>
		<link>http://redsouljaz.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://redsouljaz.wordpress.com/osd.xml" title="Redsouljaz&#039;s Blog" />
	<atom:link rel='hub' href='http://redsouljaz.wordpress.com/?pushpress=hub'/>
		<item>
		<title>VB.NET Date Time Format Patterns</title>
		<link>http://redsouljaz.wordpress.com/2010/01/15/vb-net-date-time-format-patterns/</link>
		<comments>http://redsouljaz.wordpress.com/2010/01/15/vb-net-date-time-format-patterns/#comments</comments>
		<pubDate>Fri, 15 Jan 2010 03:02:53 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[Date Time Format Patterns]]></category>
		<category><![CDATA[datetime format]]></category>
		<category><![CDATA[VB.NET Date Time Format Patterns]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=241</guid>
		<description><![CDATA[Standard Format Example List: Format Code Result MM/dd/yyyy Date.Now().ToString(&#8220;d&#8221;) 1/15/2010 dddd, dd MMMM yyyy Date.Now().ToString(&#8220;D&#8221;) Friday, January 15, 2010 dddd, dd MMMM yyyy hh:mm tt Date.Now().ToString(&#8220;f&#8221;) Friday, January 15, 2010 11:06 AM dddd, dd MMMM yyyy HH:mm:ss Date.Now().ToString(&#8220;F&#8221;) Friday, January 15, 2010 11:06:46 AM MM/dd/yyyy h:mm tt Date.Now().ToString(&#8220;g&#8221;) 1/15/2010 11:06 AM MM/dd/yyyy HH:mm:ss Date.Now().ToString(&#8220;G&#8221;) 1/15/2010 [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=241&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<div>
<p><strong> Standard Format Example List:</strong></p>
<table style="width:100%;height:243px;" border="1" cellspacing="1" cellpadding="1">
<tbody>
<tr>
<td class="style2"><strong><span style="font-family:Arial;font-size:x-small;">Format</span></strong></td>
<td class="style1"><strong><span style="font-family:Arial;font-size:x-small;">Code</span></strong></td>
<td><strong><span style="font-family:Arial;font-size:x-small;">Result</span></strong></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">MM/dd/yyyy</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;d&#8221;)</span></td>
<td><span id="Label1">1/15/2010</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">dddd, dd MMMM yyyy</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;D&#8221;)</span></td>
<td><span id="Label2">Friday, January 15, 2010</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">dddd, dd MMMM yyyy hh:mm	 tt</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;f&#8221;)</span></td>
<td><span id="Label3">Friday, January 15, 2010 11:06 AM</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">dddd, dd MMMM yyyy HH:mm:ss</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;F&#8221;)</span></td>
<td><span id="Label4">Friday, January 15, 2010 11:06:46 AM</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">MM/dd/yyyy h:mm tt</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;g&#8221;)</span></td>
<td><span id="Label5">1/15/2010 11:06 AM</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">MM/dd/yyyy HH:mm:ss</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;G&#8221;)</span></td>
<td><span id="Label6">1/15/2010 11:06:46 AM</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">MMMM dd</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;m&#8221;)</span></td>
<td><span id="Label7">January 15</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">dd MMM yyyy HH&#8217;:'mm&#8217;:'ss &#8216;GMT&#8217;</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;r&#8221;)</span></td>
<td><span id="Label8">Fri, 15 Jan 2010 11:06:46 GMT</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">yyyy&#8217;-'MM&#8217;-'dd&#8217;T'HH&#8217;:'mm&#8217;:'ss</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;s&#8221;)</span></td>
<td><span id="Label9">2010-01-15T11:06:46</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">yyyy&#8217;-'MM&#8217;-'dd HH&#8217;:'mm&#8217;:'ss&#8217;Z&#8217;</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;u&#8221;)</span></td>
<td><span id="Label10">2010-01-15 11:06:46Z</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">dddd, MMMM dd yyyy HH:mm:ss</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;U&#8221;)</span></td>
<td><span id="Label11">Friday, January 15, 2010 3:06:46 AM</span></td>
</tr>
<tr>
<td class="style2"><span style="font-family:Arial;font-size:x-small;">yyyy MMMM</span></td>
<td class="style1"><span style="font-family:Arial;font-size:x-small;">Date.Now().ToString(&#8220;y&#8221;)</span></td>
<td><span id="Label12">January, 2010</span></td>
</tr>
</tbody>
</table>
</div>
<p><a href="http://redsouljaz.com/2010/01/15/vb-net-date-time-format-patterns/">Read More Complete List &gt;&gt;</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/241/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/241/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/241/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/241/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/241/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/241/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/241/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/241/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/241/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/241/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/241/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/241/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/241/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/241/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=241&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2010/01/15/vb-net-date-time-format-patterns/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>
	</item>
		<item>
		<title>ASP.NET: How to read XML Data String to Dataset</title>
		<link>http://redsouljaz.wordpress.com/2009/12/02/asp-net-how-to-read-xml-data-string-to-dataset/</link>
		<comments>http://redsouljaz.wordpress.com/2009/12/02/asp-net-how-to-read-xml-data-string-to-dataset/#comments</comments>
		<pubDate>Wed, 02 Dec 2009 13:54:43 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Convert xml to dataset]]></category>
		<category><![CDATA[dataset]]></category>
		<category><![CDATA[How to convert XML data of web service into DataSet]]></category>
		<category><![CDATA[How to read XML Data String to Dataset]]></category>
		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=233</guid>
		<description><![CDATA[The output of XML String: &#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34; ?&#62; - &#60;NewDataSet&#62; - &#60;Table&#62; &#60;CONDOM&#62;Durex&#60;/CONDOM&#62; &#60;SIZE&#62;XL&#60;/SIZE&#62; &#60;QTY&#62;123&#60;/QTY&#62; &#60;COLOR&#62;616&#60;/COLOR&#62; &#60;/Table&#62; &#60;/NewDataSet&#62; In order to convert from XML to dataset, this is the code: Dim MyDS as new Dataset(&#34;Table1&#34;) Dim strReader As StringReader = New StringReader(YourXmlString) MyDS.ReadXml(strReader)<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=233&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>The output of XML String:</p>
<pre class="brush: xml;">
&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot; ?&gt;
- &lt;NewDataSet&gt;
- &lt;Table&gt;
 &lt;CONDOM&gt;Durex&lt;/CONDOM&gt;
 &lt;SIZE&gt;XL&lt;/SIZE&gt;
 &lt;QTY&gt;123&lt;/QTY&gt;
 &lt;COLOR&gt;616&lt;/COLOR&gt;
 &lt;/Table&gt;
 &lt;/NewDataSet&gt;
</pre>
<p>In order to convert from XML to dataset, this is the code:</p>
<pre class="brush: vb;">
     Dim MyDS as new Dataset(&quot;Table1&quot;)
     Dim strReader As StringReader = New StringReader(YourXmlString)
     MyDS.ReadXml(strReader)
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/233/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/233/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/233/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/233/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/233/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/233/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/233/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/233/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/233/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/233/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/233/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/233/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/233/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/233/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=233&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/12/02/asp-net-how-to-read-xml-data-string-to-dataset/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>
	</item>
		<item>
		<title>ASP.NET: Convert String XML to XML Node</title>
		<link>http://redsouljaz.wordpress.com/2009/12/02/asp-net-convert-string-xml-to-xml-node/</link>
		<comments>http://redsouljaz.wordpress.com/2009/12/02/asp-net-convert-string-xml-to-xml-node/#comments</comments>
		<pubDate>Wed, 02 Dec 2009 13:42:50 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Convert String XML to XML Node]]></category>
		<category><![CDATA[looping xmlnodelist]]></category>
		<category><![CDATA[XML]]></category>
		<category><![CDATA[xmlNode]]></category>
		<category><![CDATA[xmlnodelist]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=228</guid>
		<description><![CDATA[For example I have string value like this: &#60;?xml version=&#34;1.0&#34;?&#62; &#60;Product type=&#34;Condom&#34;&#62; &#60;CondomName&#62;durex&#60;/CondomName&#62; &#60;ExpDate&#62;False&#60;/ExpDate&#62; &#60;Type&#62;False&#60;/Type&#62; &#60;Color&#62;False&#60;/Color&#62; &#60;Qty&#62;False&#60;/Qty&#62; &#60;/Product&#62; Since this this is a string value, so we need to convert to xml node to be able to process. So this is the code: Imports System.Xml Imports System.Xml.Serialization Dim xmlNodeList As System.Xml.XmlNodeList Dim xmlNode As System.Xml.XmlNode [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=228&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>For example I have string value like this:</p>
<pre class="brush: xml;">
    &lt;?xml version=&quot;1.0&quot;?&gt;
           &lt;Product type=&quot;Condom&quot;&gt;
                &lt;CondomName&gt;durex&lt;/CondomName&gt;
                &lt;ExpDate&gt;False&lt;/ExpDate&gt;
                &lt;Type&gt;False&lt;/Type&gt;
                &lt;Color&gt;False&lt;/Color&gt;
                &lt;Qty&gt;False&lt;/Qty&gt;
            &lt;/Product&gt;
</pre>
<p>Since this this is a string value, so we need to convert to xml node to be able to process.<br />
So this is the code:</p>
<pre class="brush: vb;">
        Imports System.Xml
        Imports System.Xml.Serialization

        Dim xmlNodeList As System.Xml.XmlNodeList
        Dim xmlNode As System.Xml.XmlNode
        Dim XmlDoc As New XmlDocument

	Dim _condomName as String
	Dim _ExpDate as String
	Dim _Type as String
	Dim _color as String
	Dim _qty as String

        XmlDoc.LoadXml(result)
	'Select the 1st Xml Element
        xmlNodeList = XmlDoc.GetElementsByTagName(&quot;Product&quot;)
	'Because only 1 Product Element, so select index by 0
        xmlNode = xmlNodeList.Item(0)

        _condomName = xmlNode.SelectSingleNode(&quot;CondomName&quot;).InnerText
        _ExpDate = xmlNode.SelectSingleNode(&quot;ExpDate&quot;).InnerText
        _Type = xmlNode.SelectSingleNode(&quot;Type&quot;).InnerText
        _color = xmlNode.SelectSingleNode(&quot;Color&quot;).InnerText
        _qty = False 'xmlNode.SelectSingleNode(&quot;Qty&quot;).InnerText
</pre>
<p>If you have more than 1 product, you need to loop the xmlList:</p>
<pre class="brush: vb;">
For Each xmlNode As XmlNode In xmlNodeList
        _condomName = xmlNode.SelectSingleNode(&quot;CondomName&quot;).InnerText
        _ExpDate = xmlNode.SelectSingleNode(&quot;ExpDate&quot;).InnerText
        _Type = xmlNode.SelectSingleNode(&quot;Type&quot;).InnerText
        _color = xmlNode.SelectSingleNode(&quot;Color&quot;).InnerText
        _qty = False 'xmlNode.SelectSingleNode(&quot;Qty&quot;).InnerText
Next
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/228/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/228/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/228/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/228/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/228/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/228/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/228/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/228/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/228/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/228/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/228/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/228/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/228/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/228/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=228&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/12/02/asp-net-convert-string-xml-to-xml-node/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>
	</item>
		<item>
		<title>ASP.NET: How to use Javascript alert inside AJAX UpdatePanel</title>
		<link>http://redsouljaz.wordpress.com/2009/12/02/asp-net-how-to-use-javascript-alert-inside-ajax-updatepanel/</link>
		<comments>http://redsouljaz.wordpress.com/2009/12/02/asp-net-how-to-use-javascript-alert-inside-ajax-updatepanel/#comments</comments>
		<pubDate>Wed, 02 Dec 2009 13:12:50 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[AJAX UpdatePanel]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Javascript alert inside AJAX UpdatePanel]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=210</guid>
		<description><![CDATA[Normally when we add Javascript Alert to our asp.net it will be like this: Page. ClientScript.RegisterStartupScript(this.GetType(), &#34;winPop&#34;, &#34;alert('Update is successful') but this code is not working if you using the code inside update panel. So in order to add javascript in update panel you need to register you client script to your script manager as [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=210&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><span style="font-size:small;"> </span></p>
<div id="_mcePaste">
<div id="_mcePaste">Normally when we add Javascript Alert to our asp.net it will be like this:</div>
<div></div>
<div>
<pre class="brush: css;">
Page. ClientScript.RegisterStartupScript(this.GetType(), &quot;winPop&quot;, &quot;alert('Update is successful')
</pre>
</div>
<div></div>
<div id="_mcePaste">but this code is not working if you using the code inside update panel.</div>
<div id="_mcePaste"></div>
<div id="_mcePaste">So in order to add javascript in update panel you need to register you client script to your script manager as shown below:</div>
<div id="_mcePaste"></div>
<div>
<pre class="brush: css;">
ScriptManager.RegisterClientScriptBlock(Page, Page.GetType(), Guid.NewGuid().ToString(), &quot;alert('Update is successfu.');&quot;,True)</pre>
<p></span></div>
</div>
<pre>
 
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/210/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/210/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/210/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/210/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/210/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/210/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/210/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/210/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/210/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/210/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/210/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/210/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/210/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/210/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=210&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/12/02/asp-net-how-to-use-javascript-alert-inside-ajax-updatepanel/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>
	</item>
		<item>
		<title>SSIS: Update data from different table if data is Null</title>
		<link>http://redsouljaz.wordpress.com/2009/11/30/ssis-update-data-from-different-table-if-data-is-null/</link>
		<comments>http://redsouljaz.wordpress.com/2009/11/30/ssis-update-data-from-different-table-if-data-is-null/#comments</comments>
		<pubDate>Mon, 30 Nov 2009 13:10:32 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[Data Flow Task]]></category>
		<category><![CDATA[Lookup transformation]]></category>
		<category><![CDATA[OLE DB Command transformation]]></category>
		<category><![CDATA[Ole DB Connection]]></category>
		<category><![CDATA[OLE DB Source]]></category>
		<category><![CDATA[SSIS]]></category>
		<category><![CDATA[SSIS: Update data from different table if data is Null]]></category>
		<category><![CDATA[Update data from different table if data is Null]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=194</guid>
		<description><![CDATA[SSIS: SSIS stands for SQL Server Integration Services. It is the new data transformation standard for SQL Server 2005 and has replaced the old SQL Server Data Transformation Services. In this post, I want to show how to update data from different table with condition that the data is Null. 1st Table is Person.Address and [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=194&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><strong>SSIS: SSIS stands for SQL Server Integration Services</strong>.  It is the new data transformation standard for SQL Server 2005 and has replaced the old SQL Server Data Transformation Services.</p>
<p>In this post, I want to show how to update data from different table with condition that the data is Null.</p>
<p style="text-align:left;">1st Table is <strong>Person.Address</strong> and 2nd table is <strong>Address2</strong><br />
<a href="http://redsouljaz.files.wordpress.com/2009/11/1.png"><img class="size-full wp-image-195 aligncenter" title="1" src="http://redsouljaz.files.wordpress.com/2009/11/1.png?w=459&#038;h=238" alt="" width="459" height="238" /></a></p>
<p>Now I want to update data in column AddressLine2 in Person.Address by using data in Address2 with condition that AddressID is same and AddressLine2 in Person.Address is Null</p>
<p>So 1st we create <strong>Data Flow Task</strong> in Control Flow tab<br />
<a href="http://redsouljaz.files.wordpress.com/2009/11/2.png"><img class="alignnone size-full wp-image-196" title="2" src="http://redsouljaz.files.wordpress.com/2009/11/2.png?w=144&#038;h=53" alt="" width="144" height="53" /></a></p>
<p style="text-align:left;">Create new <strong>Ole DB Connection</strong> in Connection manager, and add the flow that looks like below figures<br />
<a href="http://redsouljaz.files.wordpress.com/2009/11/3.png"><img class="size-full wp-image-197 aligncenter" title="3" src="http://redsouljaz.files.wordpress.com/2009/11/3.png?w=369&#038;h=684" alt="" width="369" height="684" /></a></p>
<p style="text-align:left;">In the <strong>OLE DB Source</strong>, add the table Person.Address<br />
In the <strong>Lookup</strong>, Add table Address2. In the column tab at the lookup editor set like this:<br />
<a href="http://redsouljaz.files.wordpress.com/2009/11/4.png"><img class="size-full wp-image-198 aligncenter" title="4" src="http://redsouljaz.files.wordpress.com/2009/11/4.png?w=499&#038;h=550" alt="" width="499" height="550" /></a></p>
<p>So this <strong>Lookup transformation</strong> is actually add a new column from other table based on addressed.</p>
<p style="text-align:left;">The <strong>Derived Column transformation</strong> creates new column or replacing current column values by applying expressions to transformation input columns. An expression can contain any combination of variables, functions, operators, and columns from the transformation input. So from we need this to replace the new column (AddressLine2) from table Address2 into column AddressLine2 in table Person.Address<br />
<a href="http://redsouljaz.files.wordpress.com/2009/11/5.png"><img class="size-full wp-image-199 aligncenter" title="5" src="http://redsouljaz.files.wordpress.com/2009/11/5.png?w=500&#038;h=470" alt="" width="500" height="470" /></a></p>
<p>First we choose Replace ‘OLE DB Source.AddressLine2’ in Derived Column, then we add expression:</p>
<p><em>(ISNULL([OLE DB Source].AddressLine2) ? Lookup.AddressLine2 : [OLE DB Source].AddressLine2)</em></p>
<p>The OLE DB Command transformation runs an SQL statement for each row in a data flow. For example, you can run an SQL statement that inserts, updates, or deletes rows in a database table. So in this case, we need this transformation to update current data.</p>
<p>In Advanced Editor for Ole DB Command, in the component properties add SQL Command:</p>
<p><em>update Person.Address set AddressLine2 = ?<br />
where AddressID = ?</em></p>
<p style="text-align:left;">Question mark indicate the parameter. Just remember the sequence of the parameter.<br />
After we fill in the <strong>Sql Command</strong>, choose Column Mappings Tab and point the Available input columns to the Available Destination Columns based on the parameter that already created.<br />
<a href="http://redsouljaz.files.wordpress.com/2009/11/6.png"><img class="size-full wp-image-200 aligncenter" title="6" src="http://redsouljaz.files.wordpress.com/2009/11/6.png?w=500&#038;h=513" alt="" width="500" height="513" /></a></p>
<p>Then execute the package</p>
<p style="text-align:left;">Result:<br />
<a href="http://redsouljaz.files.wordpress.com/2009/11/7.png"><img class="size-full wp-image-201 aligncenter" title="7" src="http://redsouljaz.files.wordpress.com/2009/11/7.png?w=351&#038;h=263" alt="" width="351" height="263" /></a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/194/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/194/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/194/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=194&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/11/30/ssis-update-data-from-different-table-if-data-is-null/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/11/1.png" medium="image">
			<media:title type="html">1</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/11/2.png" medium="image">
			<media:title type="html">2</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/11/3.png" medium="image">
			<media:title type="html">3</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/11/4.png" medium="image">
			<media:title type="html">4</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/11/5.png" medium="image">
			<media:title type="html">5</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/11/6.png" medium="image">
			<media:title type="html">6</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/11/7.png" medium="image">
			<media:title type="html">7</media:title>
		</media:content>
	</item>
		<item>
		<title>ASP.NET &#8211; Convert CSV to Dataset</title>
		<link>http://redsouljaz.wordpress.com/2009/07/17/asp-net-convert-csv-to-dataset/</link>
		<comments>http://redsouljaz.wordpress.com/2009/07/17/asp-net-convert-csv-to-dataset/#comments</comments>
		<pubDate>Fri, 17 Jul 2009 06:29:01 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[convert csv to dataset]]></category>
		<category><![CDATA[csv]]></category>
		<category><![CDATA[csv to dataset]]></category>
		<category><![CDATA[dataset]]></category>
		<category><![CDATA[import csv]]></category>
		<category><![CDATA[load csv]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/2009/07/17/asp-net-convert-csv-to-dataset/</guid>
		<description><![CDATA[Here is the function to convert CSV file to dataset in asp.net using vb.net.First you need to upload the csv file into your web server, then save the file path.Add this function code: Private Shared Function getCsvToDataset(ByVal strPath As String) As DataSet Dim strLine As String Dim strArray As String() Dim charArray As Char() = [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=191&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Here is the function to convert CSV file to dataset in asp.net using vb.net.<br />First you need to upload the csv file into your web server, then save the file path.<br />Add this function code:</p>
<p>
<pre class="brush: css;">

    Private Shared Function getCsvToDataset(ByVal strPath As String) As DataSet
        Dim strLine As String
        Dim strArray As String()
        Dim charArray As Char() = New Char() {&quot;,&quot;c}
        Dim ds As New DataSet()
        Dim dt As DataTable = ds.Tables.Add(&quot;TheData&quot;)
        Dim aFile As New FileStream(strPath, FileMode.Open)
        Dim sr As New StreamReader(aFile)

        strLine = sr.ReadLine()

        strArray = strLine.Split(charArray)

        For x As Integer = 0 To strArray.GetUpperBound(0)
            dt.Columns.Add(strArray(x).Trim())
        Next

        strLine = sr.ReadLine()
        While strLine IsNot Nothing
            strArray = strLine.Split(charArray)
            Dim dr As DataRow = dt.NewRow()
            For i As Integer = 0 To strArray.GetUpperBound(0)
                dr(i) = strArray(i).Trim()
            Next
            dt.Rows.Add(dr)
            strLine = sr.ReadLine()
        End While
        sr.Close()
        Return ds
    End Function
</pre>
<p>I think, this is the most effective way to convert csv to dataset. Before this, I already try to use Microsoft.Jet.OLEDB.4.0 but the problem that shows an error message in finding csv file on the web server. So this method using FileStream is the best way.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/191/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/191/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/191/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/191/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/191/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/191/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/191/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/191/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/191/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/191/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/191/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/191/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/191/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/191/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=191&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/07/17/asp-net-convert-csv-to-dataset/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>
	</item>
		<item>
		<title>Go green and Recycle design for E-mail signature V1</title>
		<link>http://redsouljaz.wordpress.com/2009/07/11/go-green-and-recycle-design-for-e-mail-signature-v1/</link>
		<comments>http://redsouljaz.wordpress.com/2009/07/11/go-green-and-recycle-design-for-e-mail-signature-v1/#comments</comments>
		<pubDate>Sat, 11 Jul 2009 09:03:10 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[Go Green]]></category>
		<category><![CDATA[e-mail signature]]></category>
		<category><![CDATA[Go green signature]]></category>
		<category><![CDATA[recycle]]></category>
		<category><![CDATA[reduce]]></category>
		<category><![CDATA[reduce reuse recycle]]></category>
		<category><![CDATA[reuse]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=182</guid>
		<description><![CDATA[These are some of my vector design that can be used for e-mail signature Image Link &#60;img src=&#34;http://redsouljaz.files.wordpress.com/2009/07/go-green3.jpg&#34; alt=&#34;GO-GREEN3&#34; title=&#34;GO-GREEN3&#34; width=&#34;430&#34; height=&#34;59&#34; class=&#34;aligncenter size-full wp-image-183&#34; /&#62; Image Link &#60;img src=&#34;http://redsouljaz.files.wordpress.com/2009/07/go-green4.jpg&#34; alt=&#34;GO-GREEN4&#34; title=&#34;GO-GREEN4&#34; width=&#34;398&#34; height=&#34;102&#34; class=&#34;aligncenter size-full wp-image-186&#34; /&#62; Image Link &#60;img src=&#34;http://redsouljaz.files.wordpress.com/2009/07/recycle.jpg&#34; alt=&#34;recycle&#34; title=&#34;recycle&#34; width=&#34;247&#34; height=&#34;106&#34; class=&#34;aligncenter size-full wp-image-187&#34; /&#62; Image Link &#60;img src=&#34;http://redsouljaz.files.wordpress.com/2009/07/recycle2.jpg&#34; alt=&#34;recycle2&#34; [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=182&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>These are some of my vector design that can be used for e-mail signature</p>
<p><img src="http://redsouljaz.files.wordpress.com/2009/07/go-green3.jpg?w=430&#038;h=59" alt="GO-GREEN3" title="GO-GREEN3" width="430" height="59" class="aligncenter size-full wp-image-183" /></p>
<p>Image Link</p>
<pre class="brush: css;">
&lt;img src=&quot;http://redsouljaz.files.wordpress.com/2009/07/go-green3.jpg&quot; alt=&quot;GO-GREEN3&quot; title=&quot;GO-GREEN3&quot; width=&quot;430&quot; height=&quot;59&quot; class=&quot;aligncenter size-full wp-image-183&quot; /&gt;
</pre>
<p><img src="http://redsouljaz.files.wordpress.com/2009/07/go-green4.jpg?w=398&#038;h=102" alt="GO-GREEN4" title="GO-GREEN4" width="398" height="102" class="aligncenter size-full wp-image-186" /></p>
<p>Image Link</p>
<pre class="brush: css;">
&lt;img src=&quot;http://redsouljaz.files.wordpress.com/2009/07/go-green4.jpg&quot; alt=&quot;GO-GREEN4&quot; title=&quot;GO-GREEN4&quot; width=&quot;398&quot; height=&quot;102&quot; class=&quot;aligncenter size-full wp-image-186&quot; /&gt;
</pre>
<p><img src="http://redsouljaz.files.wordpress.com/2009/07/recycle.jpg?w=247&#038;h=106" alt="recycle" title="recycle" width="247" height="106" class="aligncenter size-full wp-image-187" /></p>
<p>Image Link</p>
<pre class="brush: css;">
&lt;img src=&quot;http://redsouljaz.files.wordpress.com/2009/07/recycle.jpg&quot; alt=&quot;recycle&quot; title=&quot;recycle&quot; width=&quot;247&quot; height=&quot;106&quot; class=&quot;aligncenter size-full wp-image-187&quot; /&gt;
</pre>
<p><img src="http://redsouljaz.files.wordpress.com/2009/07/recycle2.jpg?w=328&#038;h=74" alt="recycle2" title="recycle2" width="328" height="74" class="aligncenter size-full wp-image-188" /></p>
<p>Image Link</p>
<pre class="brush: css;">
&lt;img src=&quot;http://redsouljaz.files.wordpress.com/2009/07/recycle2.jpg&quot; alt=&quot;recycle2&quot; title=&quot;recycle2&quot; width=&quot;328&quot; height=&quot;74&quot; class=&quot;aligncenter size-full wp-image-188&quot; /&gt;
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/182/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/182/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/182/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/182/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/182/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/182/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/182/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/182/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/182/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/182/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/182/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/182/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/182/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/182/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=182&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/07/11/go-green-and-recycle-design-for-e-mail-signature-v1/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/07/go-green3.jpg" medium="image">
			<media:title type="html">GO-GREEN3</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/07/go-green3.jpg" medium="image">
			<media:title type="html">GO-GREEN3</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/07/go-green4.jpg" medium="image">
			<media:title type="html">GO-GREEN4</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/07/go-green4.jpg" medium="image">
			<media:title type="html">GO-GREEN4</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/07/recycle.jpg" medium="image">
			<media:title type="html">recycle</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/07/recycle.jpg" medium="image">
			<media:title type="html">recycle</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/07/recycle2.jpg" medium="image">
			<media:title type="html">recycle2</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/07/recycle2.jpg" medium="image">
			<media:title type="html">recycle2</media:title>
		</media:content>
	</item>
		<item>
		<title>ASP.NET Cross Tab / Pivot from Data Table</title>
		<link>http://redsouljaz.wordpress.com/2009/06/22/asp-net-cross-tab-pivot-from-data-table/</link>
		<comments>http://redsouljaz.wordpress.com/2009/06/22/asp-net-cross-tab-pivot-from-data-table/#comments</comments>
		<pubDate>Mon, 22 Jun 2009 07:16:46 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[cross tab]]></category>
		<category><![CDATA[cross table]]></category>
		<category><![CDATA[data table to cross tab]]></category>
		<category><![CDATA[datatable]]></category>
		<category><![CDATA[function cross tab]]></category>
		<category><![CDATA[pivot]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=170</guid>
		<description><![CDATA[Sometimes when you working with the large data, you might want to display the data in pivot table / cross tab. Crystal report have a very nice wizard to make our life easier to create cross tab, but not in vb.net For example you have data table like Table CompanyDetail populated from the SQL Select [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=170&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Sometimes when you working with the large data, you might want to display the data in pivot table / cross tab. Crystal report have a very nice wizard to make our life easier to create cross tab, but not in vb.net</p>
<p>For example you have data table like Table CompanyDetail populated from the SQL Select Query below</p>
<table cellspacing="0" cellpadding="3" rules="cols" border="0" id="GridView1" style="color:Black;background-color:White;border-collapse:collapse;border-color:#999999;border-width:0;">
<tr style="color:White;background-color:Black;font-weight:bold;">
<th scope="col">company_code</th>
<th scope="col">PAY_AMOUNT</th>
<th scope="col">tax_period_month</th>
</tr>
<tr style="border-color:Black;border-style:Solid;">
<td>777</td>
<td>3000,0000</td>
<td>05</td>
</tr>
<tr style="background-color:#CCCCCC;border-color:Black;border-style:Solid;">
<td>777</td>
<td>2000,0000</td>
<td>08</td>
</tr>
<tr style="border-color:Black;border-style:Solid;">
<td>777</td>
<td>1000,0000</td>
<td>11</td>
</tr>
<tr style="background-color:#CCCCCC;border-color:Black;border-style:Solid;">
<td>1010000</td>
<td>4000,0000</td>
<td>11</td>
</tr>
<tr style="border-color:Black;border-style:Solid;">
<td>777</td>
<td>5000,0000</td>
<td>11</td>
</tr>
</table>
<p>And you want to display into this order:</p>
<table cellspacing="0" cellpadding="3" rules="cols" border="1" id="GridView1" style="color:Black;background-color:White;border-collapse:collapse;border-color:#999999;border-style:Solid;border-width:1px;">
<tr style="color:White;background-color:Black;font-weight:bold;">
<th scope="col">company_code</th>
<th scope="col">05</th>
<th scope="col">08</th>
<th scope="col">11</th>
</tr>
<tr style="border-color:Black;border-style:Solid;">
<td>777</td>
<td>3000,0000</td>
<td>2000,0000</td>
<td>6000,0000</td>
</tr>
<tr style="background-color:#CCCCCC;border-color:Black;border-style:Solid;">
<td>1010000</td>
<td>&nbsp;</td>
<td>&nbsp;</td>
<td>4000,0000</td>
</tr>
</table>
<p>So Here is the step to convert Data Table data into pivot table<br />
Step1. Create this function:</p>
<p>ColumnX = Is the Column that you want to make cross tab (In this example is tax_period_month)<br />
ColumnY = Is the column that will be put in the left column (company_code)<br />
ColumnZ = Is the total value from combining columnX and columnY (PAY_AMOUNT)</p>
<pre class="brush: css;">

    Function GetInversedDataTable(ByVal table As DataTable, ByVal columnX As String, ByVal columnY As String, ByVal columnZ As String, ByVal nullValue As String, ByVal sumValues As Boolean) As DataTable
        'Create a DataTable to Return
        Dim returnTable As New DataTable()

        If columnX = &quot;&quot; Then
            columnX = table.Columns(0).ColumnName
        End If

        'Add a Column at the beginning of the table
        returnTable.Columns.Add(columnY)

        'Read all DISTINCT values from columnX Column in the provided DataTale
        Dim columnXValues As New List(Of String)()

        For Each dr As DataRow In table.Rows

            Dim columnXTemp As String = dr(columnX).ToString()
            If Not columnXValues.Contains(columnXTemp) Then
                'Read each row value, if it's different from others provided, add to the list of values and creates a new Column with its value.
                columnXValues.Add(columnXTemp)
                returnTable.Columns.Add(columnXTemp)
            End If
        Next

        'Verify if Y and Z Axis columns re provided
        If columnY &lt;&gt; &quot;&quot; AndAlso columnZ &lt;&gt; &quot;&quot; Then
            'Read DISTINCT Values for Y Axis Column
            Dim columnYValues As New List(Of String)()

            For Each dr As DataRow In table.Rows
                If Not columnYValues.Contains(dr(columnY).ToString()) Then
                    columnYValues.Add(dr(columnY).ToString())
                End If
            Next

            'Loop all Column Y Distinct Value
            For Each columnYValue As String In columnYValues
                'Creates a new Row
                Dim drReturn As DataRow = returnTable.NewRow()
                drReturn(0) = columnYValue
                'foreach column Y value, The rows are selected distincted
                Dim rows As DataRow() = table.[Select]((columnY &amp; &quot;='&quot;) + columnYValue &amp; &quot;'&quot;)

                'Read each row to fill the DataTable
                For Each dr As DataRow In rows
                    Dim rowColumnTitle As String = dr(columnX).ToString()

                    'Read each column to fill the DataTable
                    For Each dc As DataColumn In returnTable.Columns
                        If dc.ColumnName = rowColumnTitle Then
                            'If Sum of Values is True it try to perform a Sum
                            'If sum is not possible due to value types, the value displayed is the last one read
                            If sumValues Then
                                Try
                                    drReturn(rowColumnTitle) = Convert.ToDecimal(drReturn(rowColumnTitle)) + Convert.ToDecimal(dr(columnZ))
                                Catch
                                    drReturn(rowColumnTitle) = dr(columnZ)
                                End Try
                            Else
                                drReturn(rowColumnTitle) = dr(columnZ)

                            End If
                        End If
                    Next
                Next

                returnTable.Rows.Add(drReturn)

            Next
        Else
            Throw New Exception(&quot;The columns to perform inversion are not provided&quot;)
        End If

        'if a nullValue is provided, fill the datable with it
        If nullValue &lt;&gt; &quot;&quot; Then
            For Each dr As DataRow In returnTable.Rows
                For Each dc As DataColumn In returnTable.Columns
                    If dr(dc.ColumnName).ToString() = &quot;&quot; Then
                        dr(dc.ColumnName) = nullValue
                    End If
                Next
            Next
        End If

        Return returnTable
    End Function
</pre>
<p>Step 2: Add gridview to the page and create connection to database to set data table:</p>
<pre class="brush: css;">
 Dim conn As SqlConnection = Nothing
        Try
            Dim connString As String = &quot;Data Source=;Initial Catalog=;Integrated Security=True&quot;

            conn = New SqlConnection(connString)
            Dim query As String = &quot;select company_code, PAY_AMOUNT, tax_period_month from ttSSP0 order by tax_period_month&quot;
            Dim cmd As SqlCommand = New SqlCommand(query, conn)
            conn.Open()
            Dim dr As SqlDataReader = cmd.ExecuteReader(CommandBehavior.CloseConnection)
            Dim dt As DataTable = New DataTable()
            Dim dt2 As DataTable = New DataTable()
            dt.Load(dr)
            dt2 = GetInversedDataTable(dt, &quot;tax_period_month&quot;, &quot;company_code&quot;, &quot;PAY_AMOUNT&quot;, &quot;&quot;, True)
            GridView1.DataSource = dt2
            GridView1.DataBind()
        Catch ex As SqlException
            ' handle error
        Catch ex As Exception
            ' handle error
        Finally
            conn.Close()
        End Try
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/170/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/170/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/170/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/170/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/170/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/170/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/170/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/170/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/170/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/170/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/170/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/170/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/170/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/170/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=170&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/06/22/asp-net-cross-tab-pivot-from-data-table/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>
	</item>
		<item>
		<title>Create Multiple row / group header in gridview ASP.NET</title>
		<link>http://redsouljaz.wordpress.com/2009/06/12/create-multiple-row-group-header-in-gridview-asp-net/</link>
		<comments>http://redsouljaz.wordpress.com/2009/06/12/create-multiple-row-group-header-in-gridview-asp-net/#comments</comments>
		<pubDate>Fri, 12 Jun 2009 02:57:05 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[gridview]]></category>
		<category><![CDATA[gridview multi row header asp.net]]></category>
		<category><![CDATA[group header gridview]]></category>
		<category><![CDATA[multi row header gridview]]></category>
		<category><![CDATA[multiple row gridview]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=163</guid>
		<description><![CDATA[This article shows how to create multiple row / group header in gridview asp.net first you need to add gridview to database and set the datasource connection. After you have done with all of that, you just add this function to your code Public Sub GetMultiRowHeader(ByVal e As GridViewRowEventArgs, ByVal GetCels As SortedList) If e.Row.RowType [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=163&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This article shows how to create multiple row / group header in gridview asp.net</p>
<p><img src="http://redsouljaz.files.wordpress.com/2009/06/group-header1.jpg?w=500&#038;h=123" alt="group header" title="group header" width="500" height="123" class="aligncenter size-full wp-image-168" /></p>
<p>first you need to add gridview to database and set the datasource connection.<br />
After you have done with all of that, you just add this function to your code</p>
<pre class="brush: css;">
  Public Sub GetMultiRowHeader(ByVal e As GridViewRowEventArgs, ByVal GetCels As SortedList)

        If e.Row.RowType = DataControlRowType.Header Then
            Dim row As GridViewRow
            Dim enumCels As IDictionaryEnumerator = GetCels.GetEnumerator()

            row = New GridViewRow(-1, -1, DataControlRowType.Header, DataControlRowState.Normal)
            While enumCels.MoveNext()

                Dim count As String() = enumCels.Value.ToString().Split(Convert.ToChar(&quot;,&quot;))
                Dim Cell As TableCell
                Cell = New TableCell()
                Cell.RowSpan = Convert.ToInt16(count(2).ToString())
                Cell.ColumnSpan = Convert.ToInt16(count(1).ToString())
                Cell.Controls.Add(New LiteralControl(count(0).ToString()))
                Cell.HorizontalAlign = HorizontalAlign.Center
                Cell.ForeColor = System.Drawing.Color.White
                row.Cells.Add(Cell)
            End While

            e.Row.Parent.Controls.AddAt(0, row)
        End If
    End Sub

    Protected Sub GridView1_RowDataBound(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GridView1.RowDataBound
        'Everytime you want to add new rows header, you creat new formatcells variable
        Dim formatCells As New SortedList
        'Format cells format:&quot;
        ' formatCells.Add(&lt;Column number&gt;, &lt;Header Name,number of column to colspan, number of row to rowspan&gt;)

        formatCells.Add(&quot;1&quot;, &quot;ROW SPAN,1,2&quot;)
        formatCells.Add(&quot;2&quot;, &quot;TopGroup,4,1&quot;)
        Dim formatcells2 As New SortedList
        formatcells2.Add(&quot;1&quot;, &quot;Subgroup1,2,1&quot;)
        formatcells2.Add(&quot;2&quot;, &quot;Subgroup2,2,1&quot;)
        GetMultiRowHeader(e, formatcells2)
        GetMultiRowHeader(e, formatCells)
    End Sub
</pre>
<p>The original code is taken from this blog<br />
<a href="http://dotnetarmy.blogspot.com/2008/06/add-grouped-multiple-row-header-in.html">http://dotnetarmy.blogspot.com/2008/06/add-grouped-multiple-row-header-in.html</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/163/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/163/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/163/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/163/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/163/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/163/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/163/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/163/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/163/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/163/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/163/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/163/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/163/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/163/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=163&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/06/12/create-multiple-row-group-header-in-gridview-asp-net/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>

		<media:content url="http://redsouljaz.files.wordpress.com/2009/06/group-header1.jpg" medium="image">
			<media:title type="html">group header</media:title>
		</media:content>
	</item>
		<item>
		<title>Connecting asp.net to Sql server 2005 stored procedures into dataset</title>
		<link>http://redsouljaz.wordpress.com/2009/06/10/connecting-asp-net-to-sql-server-2005-stored-procedures-into-dataset/</link>
		<comments>http://redsouljaz.wordpress.com/2009/06/10/connecting-asp-net-to-sql-server-2005-stored-procedures-into-dataset/#comments</comments>
		<pubDate>Wed, 10 Jun 2009 07:20:30 +0000</pubDate>
		<dc:creator>Red Souldier</dc:creator>
				<category><![CDATA[VB.NET]]></category>
		<category><![CDATA[asp.net using dataset call stored procedures]]></category>
		<category><![CDATA[call sql server stored procedure]]></category>
		<category><![CDATA[dataset]]></category>
		<category><![CDATA[SqlDataReader]]></category>
		<category><![CDATA[stored procedures]]></category>
		<category><![CDATA[stored procedures to dataset]]></category>
		<category><![CDATA[using asp.net to call sql server stored procedure]]></category>

		<guid isPermaLink="false">http://redsouljaz.wordpress.com/?p=160</guid>
		<description><![CDATA[This article demonstrates how to use ASP.NET and ADO.NET with Visual Basic .NET to create and to call a Microsoft SQL Server stored procedure with an input parameter and an output parameter. 1 step create store procedure Create Procedure GetAuthorsByLastName1 (@au_lname varchar(40), @RowCount int output) as select * from authors where au_lname like @au_lname; /* [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=160&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This article demonstrates how to use ASP.NET and ADO.NET with Visual Basic .NET to create and to call a Microsoft SQL Server stored procedure with an input parameter and an output parameter.</p>
<p>1 step create store procedure</p>
<pre class="brush: css;">

Create Procedure GetAuthorsByLastName1 (@au_lname varchar(40), @RowCount int output)
as 

select * from authors where au_lname like @au_lname; 

/* @@ROWCOUNT returns the number of rows that are affected by the last statement. */
select @RowCount=@@ROWCOUNT
</pre>
<p>Call the stored procedure in asp.net code </p>
<pre class="brush: css;">
  Private Function getDataset() As DataSet
        Dim DS As DataSet
        Dim MyConnection As SqlConnection
        Dim MyDataAdapter As SqlDataAdapter

        'Create a connection to the SQL Server.
        MyConnection = New SqlConnection(&quot;server=(local);database=pubs;Trusted_Connection=yes&quot;)

        'Create a DataAdapter, and then provide the name of the stored procedure.
        MyDataAdapter = New SqlDataAdapter(&quot;GetAuthorsByLastName&quot;, MyConnection)

        'Set the command type as StoredProcedure.
        MyDataAdapter.SelectCommand.CommandType = CommandType.StoredProcedure

        'Create and add a parameter to Parameters collection for the stored procedure.
        MyDataAdapter.SelectCommand.Parameters.Add(New SqlParameter(&quot;@au_lname&quot;, _
       SqlDbType.VarChar, 40))

        'Assign the search value to the parameter.
        MyDataAdapter.SelectCommand.Parameters(&quot;@au_lname&quot;).Value = Trim(txtLastName.Text)

        'Create and add an output parameter to Parameters collection.
        MyDataAdapter.SelectCommand.Parameters.Add(New SqlParameter(&quot;@RowCount&quot;, _
        SqlDbType.Int, 4))

        'Set the direction for the parameter. This parameter returns the Rows returned.
        MyDataAdapter.SelectCommand.Parameters(&quot;@RowCount&quot;).Direction = ParameterDirection.Output

        DS = New DataSet() 'Create a new DataSet to hold the records.
        MyDataAdapter.Fill(DS, &quot;AuthorsByLastName&quot;) 'Fill the DataSet with the rows returned.

        'Get the number of rows returned, and then assign it to the variable
        Dim rowCount As String
        rowCount = MyDataAdapter.SelectCommand.Parameters(1).Value.ToString &amp; &quot; Rows Found!&quot;

        MyDataAdapter.Dispose() 'Dispose of the DataAdapter.
        MyConnection.Close() 'Close the connection.

        Return DS

    End Function
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/redsouljaz.wordpress.com/160/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/redsouljaz.wordpress.com/160/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/redsouljaz.wordpress.com/160/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/redsouljaz.wordpress.com/160/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/redsouljaz.wordpress.com/160/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/redsouljaz.wordpress.com/160/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/redsouljaz.wordpress.com/160/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/redsouljaz.wordpress.com/160/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/redsouljaz.wordpress.com/160/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/redsouljaz.wordpress.com/160/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/redsouljaz.wordpress.com/160/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/redsouljaz.wordpress.com/160/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/redsouljaz.wordpress.com/160/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/redsouljaz.wordpress.com/160/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=redsouljaz.wordpress.com&amp;blog=6722393&amp;post=160&amp;subd=redsouljaz&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://redsouljaz.wordpress.com/2009/06/10/connecting-asp-net-to-sql-server-2005-stored-procedures-into-dataset/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c7fdacaf049da9e25ae833bab2bc9d8?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">redsouljaz</media:title>
		</media:content>
	</item>
	</channel>
</rss>
