<?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/"
	>

<channel>
	<title>Pranav Bhat's Blog</title>
	<atom:link href="http://pranavbhat.com/blog/index.php/feed/" rel="self" type="application/rss+xml" />
	<link>http://pranavbhat.com/blog</link>
	<description>Software development, technology and computer science</description>
	<pubDate>Sat, 24 Apr 2010 06:34:13 +0000</pubDate>
	
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Are you a Geek?</title>
		<link>http://pranavbhat.com/blog/index.php/2010/04/are-you-a-geek/</link>
		<comments>http://pranavbhat.com/blog/index.php/2010/04/are-you-a-geek/#comments</comments>
		<pubDate>Fri, 23 Apr 2010 16:08:59 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://pranavbhat.com/blog/?p=194</guid>
		<description><![CDATA[Someone recently asked me if I consider myself a Geek and I said I don&#8217;t know,maybe! But it got me thinking who exactly is a geek? Well the definition of a geek could be very subjective and can differ for each person.
For me,you are a geek if :

Your idea of perfect life is &#8220;Eat, Sleep [...]]]></description>
			<content:encoded><![CDATA[<p>Someone recently asked me if I consider myself a Geek and I said I don&#8217;t know,maybe! But it got me thinking who exactly is a geek? Well the definition of a geek could be very subjective and can differ for each person.</p>
<p>For me,you are a geek if :</p>
<ul>
<li>Your idea of perfect life is &#8220;Eat, Sleep and Code&#8221;</li>
<li>You are highly opinionated about the superiority / inferiority of a technology or a programming language. You strongly agree / disagree to  companies&#8217;(company here means a tech company; there are no other companies in this world) policies. And of course needless to say you blog your opinions online!</li>
<li>You believe the concept of &#8220;The Matrix&#8221; is real and we all live in a computer generated world</li>
<li>And you believe all the liberal arts majors are fictitious! ( no offence intended <img src='http://pranavbhat.com/blog/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> )</li>
<li>Can live off  top raman / frozen food / Pizza / anything that can give you just about enough energy to code</li>
<li>And you can convert &#8220;Caffeine to Code&#8221;</li>
<li>You search for &#8220;How to kiss&#8221; and &#8220;How to ask a girl out&#8221; on Google</li>
<li>Your idea of proposing to a girl is to send her an encrypted message to decipher. ( if you are up for it; <a href="http://pranavbhat.com/blog/wp-content/uploads/2010/04/decipherthis.txt" target="_self">decipher this</a> )</li>
<li>You don&#8217;t buy apple products for their marketing excellence but for their technological excellence or innovation ( if any <img src='http://pranavbhat.com/blog/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' />  )</li>
</ul>
<p>Of course, this is not an exhaustive list. You can add your points in the comments section of this post.</p>
<p style="padding-left: 30px;">
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2010/04/are-you-a-geek/feed/</wfw:commentRss>
		</item>
		<item>
		<title>A Twitter Client</title>
		<link>http://pranavbhat.com/blog/index.php/2010/03/a-twitter-client/</link>
		<comments>http://pranavbhat.com/blog/index.php/2010/03/a-twitter-client/#comments</comments>
		<pubDate>Thu, 11 Mar 2010 16:06:32 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[TwitterClient]]></category>

		<category><![CDATA[jquery]]></category>

		<category><![CDATA[twitter client]]></category>

		<category><![CDATA[WPF]]></category>

		<guid isPermaLink="false">http://pranavbhat.com/blog/?p=161</guid>
		<description><![CDATA[Plans regarding the current Twitter client that I am working on and how do I plan to expand it; the tools that I am using for project management and the various technologies/frameworks/platforms I plan to use]]></description>
			<content:encoded><![CDATA[<p>Initially I thought of making a web based Twitter client that will imitate the functionality of the original Twitter website but the scope of this project has increased since then as you will see as you read this post. Of course, needless to say this project by no means is a product I want to create and launch; eventually to make money out of it. (Although it would be great if I could but chances look slim!)</p>
<p>The reason this client is web based is because I wanted to create a complete project in JQuery and have JQuery make AJAX calls to a proxy web service which will in turn make calls to the Twitter API. The proxy is needed so that the browsers won&#8217;t block AJAX requests as cross site scripting.</p>
<p>To track changes and to maintain feature lists and bug list I&#8217;m trying something different this time around. I&#8217;ve decided to use<a href="http://projects.zoho.com" target="_blank"> Zoho Projects</a> and I&#8217;ve been so far very impressed about Zoho projects. They have a very easy to use user interface and I got started with Zoho projects almost instantly! They have several features but a detailed discussion and complete review of Zoho projects deserves a seperate blog post!</p>
<p>Hence to summarize, the objectives of this project is:</p>
<ul>
<li>Create a client for popular micro-blogging service Twitter using the<a href="http://apiwiki.twitter.com" target="_blank"> Twitter API</a>.</li>
<li>Effective use of <a href="http://jquery.com" target="_blank">JQuery</a> and Javascript to create a truly AJAX/DHTML based UI using <a href="http://jqueryui.com" target="_blank">JQuery UI</a></li>
<li> Implement all the basic functions of Twitter</li>
<li>Blog about the recent development(s) of this project on this blog!</li>
</ul>
<p>Some of the basic Twitter functionality that I am targeting in the first draft of the project ( Alpha 0.0.1 if you will) is:</p>
<ul>
<li>A user would be able to get his home timeline. In Twitter API terms, a home timeline is the feed that you see when you are log into twitter. It is basically a list of Tweets by everyone whom you follow</li>
<li>A user would be able to see his public timeline. This is usually a list of tweets that are visible to public and are usually tweets that you send. You can check your public timeline by logging into Twitter and clicking on the profile link on your homepage</li>
<li>Replying and direct messaging any user on Twitter</li>
<li>Follow/ Un-follow other users</li>
<li>Post new Tweets</li>
<li>Viewing a user profile</li>
</ul>
<p>Finally, I would sign off saying that in the bigger scheme of things, I would like to create  a Twitter client for the Web (which I am currently working on right now) , a desktop client using WPF (<a href="http://en.wikipedia.org/wiki/Windows_Presentation_Foundation" target="_blank">Windows Presentation Framework</a> about which I am currently reading) and then have a client for the Android platform. Ideally all these three projects should share a lot of code (like many software engineering books suggest) and that is what I plan to accomplish in these three projects.</p>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2010/03/a-twitter-client/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Learning Python</title>
		<link>http://pranavbhat.com/blog/index.php/2009/06/learning-python/</link>
		<comments>http://pranavbhat.com/blog/index.php/2009/06/learning-python/#comments</comments>
		<pubDate>Tue, 09 Jun 2009 01:35:14 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[python]]></category>

		<category><![CDATA[learning python]]></category>

		<guid isPermaLink="false">http://pranavbhat.com/blog/?p=140</guid>
		<description><![CDATA[I have heard about Python over and over and over again and for reasons not known I have ignored Python over and over again!! But not anymore, I have finally decided to learn python and that too in the right way!
So, the other day  while coming back from the college library I picked up two [...]]]></description>
			<content:encoded><![CDATA[<p>I have heard about Python over and over and over again and for reasons not known I have ignored Python over and over again!! But not anymore, I have finally decided to learn python and that too in the right way!</p>
<p>So, the other day  while coming back from the college library I picked up two of the books on python(Learning Python and Beginning Python) and have started reading about python. I did read a couple of pages and this is what I have to summarize:</p>
<ul>
<li>Python is dynamic object oriented language</li>
<li>works on Windows, Linux/Unix and MAC OSes apart from a range of other OS</li>
<li>has simple syntax and is modular with hierarchical packages</li>
<li>newer modules can be added and modules written in C/C++, Java and even .net framework supported</li>
<li>used extensively and the demand is increasing day by day</li>
<li>And finally its open source!</li>
</ul>
<p>All the above points make python a language I definitely want to learn and I am cursing myself for not learning it for so long.  So, do check back soon as I will post about my progress of learning python. Do suggest any resources/ articles/ books on python that you might know in the comments section.</p>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2009/06/learning-python/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Value Types and Reference Types in .net</title>
		<link>http://pranavbhat.com/blog/index.php/2009/05/value-types-and-reference-types-in-net/</link>
		<comments>http://pranavbhat.com/blog/index.php/2009/05/value-types-and-reference-types-in-net/#comments</comments>
		<pubDate>Wed, 27 May 2009 13:32:25 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[.NET]]></category>

		<category><![CDATA[.net framework]]></category>

		<category><![CDATA[value types and reference types]]></category>

		<guid isPermaLink="false">http://pranavbhat.com/blog/?p=130</guid>
		<description><![CDATA[I was reading about Value types and Reference Types for the exam 70-536 which I will be giving soon and there were certain things that I already knew already but some of them were new to me and hence I thought I would have a summary post of what I understand of value types and [...]]]></description>
			<content:encoded><![CDATA[<p>I was reading about Value types and Reference Types for the exam 70-536 which I will be giving soon and there were certain things that I already knew already but some of them were new to me and hence I thought I would have a summary post of what I understand of value types and reference types in .net.</p>
<p><strong>Value Type:</strong></p>
<p>The .net CLR(Common Language Runtime) store the data of the value types in a part of the memory called as the stack. The most basic type of variables like Integers, Booleans, Bytes etc are stored as value types by the .net runtime. Value types can be easily created, updated and removed from the stack by the .net runtime.<br />
There are three types of value types:<br />
•    The built-in types of the .net framework<br />
•    The user defined types<br />
•    Enumerations.</p>
<p><strong>Reference Types:</strong></p>
<p>The .net CLR stores reference types in 2 steps; firstly the address of the memory location, called as a pointer is stored in the stack. This pointer points to the address where the actual data is stored in the part of the memory called as the heap. Reference types which are no longer referenced are garbage collected periodically by the runtime. Reference types are generally very effective in passing parameters to functions.</p>
<p>Some of the examples of reference types include strings, objects (of classes; built-in or otherwise) etc. To illustrate more, I did an experiment which demonstrates value type and reference type and how can it be detected if a variable is a value type or a reference type.</p>
<blockquote><p>SByte a = 0;<br />
Byte b = 0;<br />
Int16 c = 0;<br />
Int32 d = 0;<br />
Int64 e = 0;<br />
string s = &#8220;&#8221;;<br />
Exception ex = new Exception();<br />
object[] types = { a, b, c, d, e, s, ex };<br />
foreach (object o in types)<br />
{<br />
string value = &#8220;&#8221;;<br />
if (o.GetType().IsValueType)<br />
{<br />
value = &#8220;Value type&#8221;;<br />
}<br />
else<br />
{<br />
value = &#8220;Reference type&#8221;;<br />
}<br />
Console.WriteLine(&#8221;{0},{1}&#8221;, o.GetType(), value);<br />
}</p></blockquote>
<p>In my next post, I will write about how to create your own value type and an example of a reference type used for function calls.</p>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2009/05/value-types-and-reference-types-in-net/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Major updations to the website</title>
		<link>http://pranavbhat.com/blog/index.php/2009/05/major-updations-to-the-website/</link>
		<comments>http://pranavbhat.com/blog/index.php/2009/05/major-updations-to-the-website/#comments</comments>
		<pubDate>Wed, 20 May 2009 19:06:52 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[Everything Social]]></category>

		<category><![CDATA[Uncategorized]]></category>

		<category><![CDATA[new website updates]]></category>

		<guid isPermaLink="false">http://pranavbhat.com/blog/?p=127</guid>
		<description><![CDATA[I have had a website now for more than 2 years and earlier it was at a .info domain of my name(http://pranavbhat.info) and this was done because the .com was not available then. Recently, I got hold of a .com for my name and hence I have decided to have a website of my own [...]]]></description>
			<content:encoded><![CDATA[<p>I have had a website now for more than 2 years and earlier it was at a .info domain of my name(http://pranavbhat.info) and this was done because the .com was not available then. Recently, I got hold of a .com for my name and hence I have decided to have a website of my own with the popular .com domain.</p>
<p>I am also a big fan of the .net technologies and hence I also wanted to have a website that will have all the information about me and allow me to showcase my work in .net technologies. This prompted to me buy a Windows based web hosting plan from Godaddy.</p>
<p>Now, I can build a website in asp.net which will contain all the information about me(you can start by visiting <a href="http://pranavbhat.com" target="_self">my homepage</a>) and then following the links in the menu bar to know more about me on the about me page and about the projects that I have done on the projects page(which is under construction as I type this post).</p>
<p>Finally, you can use the contact me page to contact me about anything and everything under the sun. So, I hope you enjoy your time on this new site of mine and I will try and have a detailed post of how did I convert from my old site to the new one and how the mapping of blog posts from the old domain takes place.</p>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2009/05/major-updations-to-the-website/feed/</wfw:commentRss>
		</item>
		<item>
		<title>First Post from ScribeFire!</title>
		<link>http://pranavbhat.com/blog/index.php/2008/11/first-post-from-scribefire/</link>
		<comments>http://pranavbhat.com/blog/index.php/2008/11/first-post-from-scribefire/#comments</comments>
		<pubDate>Wed, 19 Nov 2008 05:38:28 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://pranavbhat.info/blog/2008/11/19/first-post-from-scribefire/</guid>
		<description><![CDATA[Just read somewhere about ScribeFire which lets you post articles to your blog right from your browser without even visiting or logging into your blog(well you actually have to login; its just that you dont have to visit your webpage. 
So, as soon as i read about Scribefire, i was like &#8220;this is the thing [...]]]></description>
			<content:encoded><![CDATA[<p>Just read somewhere about ScribeFire which lets you post articles to your blog right from your browser without even visiting or logging into your blog(well you actually have to login; its just that you dont have to visit your webpage. </p>
<p>So, as soon as i read about Scribefire, i was like &#8220;this is the thing i was looking for!!&#8221; and hence installed the plugin immidiately and viola; this is my first post from scribefire. If all goes well i will be posting very often using scribefire because this is kind of convinient for me to post this way; so hoping that this works out fine for me!</p>
<p></p>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2008/11/first-post-from-scribefire/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Fashion Review!</title>
		<link>http://pranavbhat.com/blog/index.php/2008/11/fashion-review/</link>
		<comments>http://pranavbhat.com/blog/index.php/2008/11/fashion-review/#comments</comments>
		<pubDate>Sun, 09 Nov 2008 13:00:13 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<category><![CDATA[fashion review]]></category>

		<category><![CDATA[indian movie fashion review]]></category>

		<guid isPermaLink="false">http://pranavbhat.info/blog/?p=108</guid>
		<description><![CDATA[I know this is kind of late since i watched the movie fashion about a week back but i have been busy; but nevertheless heres a review of the movie. The first thing that comes to my mind when i think of the movie is the fact that the movie has failed to surprise me [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone" title="Fashion the movie review" src="http://i37.tinypic.com/14kffir.jpg" alt="" width="535" height="210" />I know this is kind of late since i watched the movie fashion about a week back but i have been busy; but nevertheless heres a review of the movie. The first thing that comes to my mind when i think of the movie is the fact that the movie has failed to surprise me like other movies of madhur bhandarkar; infact the movie has disappointed me. I think the movie is not typical madhur bhandarkar and instead of showing the reality( which madhur bhandarkar) is fameous for; this time he has been politically correct for the movie.</p>
<p>The movie starts like the usual with a small town girl who dreams to make it big in the Indian modelling world and is the usual modest and cheerful girl and then as she gains success and fame she turns bitchy, arrogant and unprofessional.Then she goes into a rehab, treats herself and walks on the ramp once again. I mean thats about the stroyline with things like a couple of hot models; real life incidents from modelling world are put in and so on and so forth. So, the storyline is the same &#8220;mom and pop&#8221; storyline that is so evident in most of the movies in India; with the difference being glamour and hot chics and some real life incidents and romours put into the movie.</p>
<p>So, overall an average movie but great acting by both Priyanka Chopra and Kangana Ranaut. So, I would recommend fashion as a one time watch!!!!</p>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2008/11/fashion-review/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Happy Independence Day!</title>
		<link>http://pranavbhat.com/blog/index.php/2008/08/happy-independence-day/</link>
		<comments>http://pranavbhat.com/blog/index.php/2008/08/happy-independence-day/#comments</comments>
		<pubDate>Fri, 15 Aug 2008 17:16:25 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://pranavbhat.info/blog/?p=92</guid>
		<description><![CDATA[Here is Wishing each and every Indian in each and every part of the world a very Happy Independence day. To celebrate this independence day i found this video on youtube which is our national anthem. so, lets sing it together and celebrate our independence day!
Indian National Anthem
]]></description>
			<content:encoded><![CDATA[<p>Here is Wishing each and every Indian in each and every part of the world a very Happy Independence day. To celebrate this independence day i found this video on youtube which is our national anthem. so, lets sing it together and celebrate our independence day!</p>
<p><a href="http://www.youtube.com/watch?v=lZi3fwP09zw">Indian National Anthem</a></p>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2008/08/happy-independence-day/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Project: Web Hosting Blog</title>
		<link>http://pranavbhat.com/blog/index.php/2008/07/project-web-hosting-blog/</link>
		<comments>http://pranavbhat.com/blog/index.php/2008/07/project-web-hosting-blog/#comments</comments>
		<pubDate>Wed, 23 Jul 2008 14:10:23 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[Projects]]></category>

		<category><![CDATA[search engine optimization]]></category>

		<category><![CDATA[seo]]></category>

		<category><![CDATA[web hosting blog]]></category>

		<guid isPermaLink="false">http://pranavbhat.info/blog/?p=87</guid>
		<description><![CDATA[I just started work on a new project which in reality is a web hosting blog. The content of the project will be created by the blog owner and my work includes Search engine optimization of the blog including link building and keyword analysis and optimization. Now, Search engine optimization is pretty challenging in itself [...]]]></description>
			<content:encoded><![CDATA[<p>I just started work on a new project which in reality is a <a title="Web Hosting blog" href="http://hostingstud.com" target="_self">web hosting blog</a>. The content of the project will be created by the blog owner and my work includes Search engine optimization of the blog including link building and keyword analysis and optimization. Now, Search engine optimization is pretty challenging in itself and SEO can get very tricky with search engines changing their algorithms every now and then. I must agree this is my first project with respect to search engine optimization and hence this is more of an experiment rather than a project.</p>
<p>I am learning this new field and would post all the latest that i learn with respect to search engine optimization and keep you posted!</p>
<p>Cheers!</p>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2008/07/project-web-hosting-blog/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Send Emails using ASP.NET</title>
		<link>http://pranavbhat.com/blog/index.php/2008/07/send-emails-using-aspnet/</link>
		<comments>http://pranavbhat.com/blog/index.php/2008/07/send-emails-using-aspnet/#comments</comments>
		<pubDate>Mon, 14 Jul 2008 17:53:31 +0000</pubDate>
		<dc:creator>pranav</dc:creator>
		
		<category><![CDATA[.NET]]></category>

		<category><![CDATA[Programming]]></category>

		<category><![CDATA[emails using ASP.NET]]></category>

		<category><![CDATA[send emails]]></category>

		<guid isPermaLink="false">http://pranavbhat.info/blog/?p=86</guid>
		<description><![CDATA[Sending Emails has always been an important function of any web based application. Many web applications use emails as the basic means of communication with its users. It is used to verify a users email id; so that the user does not put someone else&#8217;s mail id instead of his or sending reminder emails, notification [...]]]></description>
			<content:encoded><![CDATA[<p>Sending Emails has always been an important function of any web based application. Many web applications use emails as the basic means of communication with its users. It is used to verify a users email id; so that the user does not put someone else&#8217;s mail id instead of his or sending reminder emails, notification and much more. Hence, in this series we see sending of emails from sending the basic email to sending complete HTML pages using various programming languages. I will mainly concentrate on PHP, ASP.NET and Java.</p>
<h3><span style="color: #808000;">Sending Email using ASP.NET</span></h3>
<p><span style="color: #000000;">Sending emails in ASP.NET is very easy especially with the use of <em>MailMessage</em> and the <em>SMTPClient</em> classes. These two classes are available in the <em>System.Net.mail</em> namespace.</span> The MailMessage class creates the mail message to send and it contains all the properties which can be used in a mail message like adding CC and BCC, adding headers and much more.</p>
<p>The <em>SMTPClient</em> class is used to send the email message using the send() function.  This function takes an argument of type <em>MailMessage.</em></p>
<p>The code to send the email is as follows:</p>
<p>Default.aspx File: (this file merely contains HTML form which will take several fields of Email).</p>
<blockquote><p>&lt;div id=&#8221;EmailForm&#8221; runat=&#8221;server&#8221;&gt;<br />
&lt;form runat=&#8221;server&#8221;&gt;<br />
&lt;table&gt;<br />
&lt;tr&gt;&lt;td&gt;Username&lt;/td&gt;&lt;td&gt;<br />
&lt;asp:TextBox ID=&#8221;userName&#8221; runat=&#8221;server&#8221;&gt;&lt;/asp:TextBox&gt;&lt;/td&gt;&lt;/tr&gt;<br />
&lt;tr&gt;&lt;td&gt;Password&lt;/td&gt;&lt;td&gt;&lt;input type=&#8221;password&#8221; runat=&#8221;server&#8221; /&gt;&lt;/td&gt;&lt;/tr&gt;<br />
&lt;tr&gt;&lt;td&gt;Outgoing SMTP server&lt;/td&gt;&lt;td&gt;&lt;asp:TextBox ID=&#8221;mailServer&#8221; runat=&#8221;server&#8221;&gt;&lt;/asp:TextBox&gt;&lt;/td&gt;&lt;td&gt;Port&lt;/td&gt;&lt;td&gt;&lt;asp:TextBox ID=&#8221;port&#8221; runat=&#8221;server&#8221; Width=&#8221;25&#8243;&gt;&lt;/asp:TextBox&gt;&lt;/td&gt;&lt;/tr&gt;<br />
&lt;tr&gt;&lt;td&gt;To:&lt;/td&gt;&lt;td&gt;&lt;asp:TextBox ID=&#8221;to1&#8243; runat=&#8221;server&#8221;&gt;&lt;/asp:TextBox&gt;&lt;/td&gt;&lt;/tr&gt;<br />
&lt;tr&gt;&lt;td&gt;Subject&lt;/td&gt;&lt;td&gt;<br />
&lt;asp:TextBox ID=&#8221;subjectinfo&#8221; runat=&#8221;server&#8221;&gt;&lt;/asp:TextBox&gt;&lt;/td&gt;&lt;/tr&gt;<br />
&lt;tr&gt;&lt;td&gt;Message&lt;td&gt;&lt;textarea id=&#8221;message&#8221; cols=&#8221;20&#8243; rows=&#8221;2&#8243; runat=&#8221;server&#8221;&gt;&lt;/textarea&gt;&lt;/td&gt;&lt;/tr&gt;<br />
&lt;tr&gt;&lt;td colspan=&#8221;2&#8243;  align=&#8221;center&#8221;&gt;&lt;asp:Button ID=&#8221;Button1&#8243; runat=&#8221;server&#8221; Text=&#8221;Send Email&#8221; /&gt;&lt;/td&gt;&lt;/tr&gt;</p>
<p>&lt;/table&gt;<br />
&lt;/form&gt;<br />
&lt;div id=&#8221;result&#8221; runat=&#8221;server&#8221;&gt;</p>
<p>&lt;/div&gt;<br />
&lt;/div&gt;</p></blockquote>
<p><!-- adman --></p>
<p>The default.aspx.vb file which handles the code for the click on the button.</p>
<blockquote><p>Imports System.Net</p>
<p>Partial Public Class _Default<br />
Inherits System.Web.UI.Page</p>
<p>Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load</p>
<p>End Sub</p>
<p>Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click<br />
Dim portno As Integer<br />
If port.Text = &#8220;&#8221; Then<br />
portno = 25<br />
Else<br />
portno = port.Text<br />
End If<br />
Dim mailmessage As System.Net.Mail.MailMessage = New Mail.MailMessage(userName.Text, to1.Text)<br />
Dim smtp As Mail.SmtpClient = New Mail.SmtpClient(mailServer.Text, portNo)</p>
<p>mailmessage.BodyEncoding = Encoding.Default<br />
mailmessage.IsBodyHtml = False<br />
mailmessage.Subject = subjectinfo.Text<br />
mailmessage.Body = message.Value</p>
<p>Try<br />
smtp.Send(mailmessage)<br />
result.InnerHtml = &#8220;&lt;b&gt;Message sent successfully&lt;/b&gt;&#8221;<br />
userName.Text = &#8220;&#8221;</p>
<p>Catch ex As Exception<br />
result.InnerHtml = &#8220;&lt;b&gt;&#8221; &amp; ex.Message &amp; &#8220;&lt;/b&gt;&#8221;</p>
<p>End Try</p>
<p>End Sub<br />
End Class</p></blockquote>
<p>Now, to send email from a SMTP server that does not require any authentication for outgoing mails can use the above code, but to send emails from an SMTP server that requires authentication( most servers these days do due to SPAM) you can make the following changes to the web.config file.</p>
<blockquote><p>&lt;system.net&gt;<br />
&lt;mailSettings&gt;</p>
<p>&lt;smtp from=&#8221;from@yourdomain.com&#8221;&gt;<br />
&lt;network host=&#8221;mail.yourdomain.com&#8221;<br />
userName=&#8221;user@yourdomain.com&#8221;<br />
password=&#8221;password-here&#8221; /&gt;<br />
&lt;/smtp&gt;<br />
&lt;/mailSettings&gt;<br />
&lt;/system.net&gt;</p></blockquote>
<p>You can download the entire <a title="Send Emails using ASP.NET source code" href="http://pranavbhat.info/blog/code/sendemails_aspnet.zip" target="_blank">source code here</a>. The source code in this file is a bit different than the above code as i made a few modifications at the last minute. Do make appropriate changes to the <strong>web.config</strong> file as shown in the above. All code in this post is written using <strong>vb.net</strong>.</p>
<p>I will also be writing code for sending emails using PHP and Java as well as writing code for more advanced functions of Mail. So, do check back for more.</p>
<p style="padding-left: 30px;">
<address></address>
]]></content:encoded>
			<wfw:commentRss>http://pranavbhat.com/blog/index.php/2008/07/send-emails-using-aspnet/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
