Sunday, October 31, 2010

Difference between Bind and Eval in asp.net

Bind is a new ASP.NET 2.0 databinding keyword. It's not a method of any specific class.
The Bind method supports read/write functionality with the ability to retrieve the values of data-bound controls and submit any changes made back to the database.

Eval is used for unidirectional (readonly) data binding, while Bind is for bi-directional (editable) databinding.
The Eval method is a static (read-only) method that takes the value of a data field and returns it as a string.

Creating RSS feed (Email subscription)

Hi all...
This is my second post...In this article.I will explain some steps that will help you to implement Email subscription for your RSS feed using asp.net application.


For creating RSS feed using asp.net 2.0 refer this link
http://www.geekpedia.com/tutorial157_Create-an-RSS-feed-using-ASP.NET-2.0.html


The structure of the  Sample RSS(xml) file will be like this.

Example –
 
<?xml version="1.0" encoding="ISO-8859-1" ?>
<rss version="2.0">


<channel>

  <title>W3Schools Home Page</title>

  <link>http://www.w3schools.com</link>

  <description>Free web building tutorials</description>

  <item>

    <title>RSS Tutorial</title>

    <link>http://www.w3schools.com/rss</link>

    <description>New RSS tutorial on W3Schools</description>

  </item>

  <item>

    <title>XML Tutorial</title>

    <link>http://www.w3schools.com/xml</link>

    <description>New XML tutorial on W3Schools</description>

  </item>

</channel>
</rss>




Steps that I followed to implement RSS feed email subscription through www.feedburner.com 

1) Using our  Gmail Id  we can  login to  feedburner website or  you  can create a  user account in feed burner.
2)After registration(free), It asks to Type your blog or feed address.There you have to specify the XML file path.

ex:- http://www.example.com/feed.xml

3) Feed burner provides users custom setting’s option  like “Email subscription”, “BUZZ on google”, ”Publish on My Twitter account”, “Post on my facebook” etc.

4) Feedburner will send the email once in a day between fixed Time interval
 
   Ex – 7.00 AM  between 9.00AM
           9.00AM  between 11.00AM
                            :::
                            :::
           5.00AM between 7.00AM
 
5) In this  scheduled time, Every day It will check for new blog on a particular day. If there is new blog on that particular date. It will send an email to the subscribed users.




Adding Face book Like Button to your asp.net application

It is now very easy to put Facebook like button on your asp.net application.
Follow these simple steps....

How this like functionality works?
Description  – You can add the Facebook like button in two ways.
1. Using XFBML
2. Face book provides a php plugin.For that we need to pass the  absolute URL path (It may be a web page OR  Image path).


This article will explain about the second option.This is the simple code snippet you need to place in your page and just pass the url u like...

<iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.blogger.com%2Fblog-options-basic.g%3FblogID%3D726200473503193201&amp;layout=standard&amp;show_faces=true&amp;width=450&amp;action=like&amp;colorscheme=light&amp;height=80" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:80px;" allowTransparency="true"></iframe>



In my case I am passing  this link  “http%3A%2F%2Fwww.blogger.com%2Fblog-options-basic.g%3FblogID%3D726200473503193201” .

Facebook provides some layout style for 'Like' button

 There are three types of  Layout Style
1.     Standard
2.     Button_Count
3.     Box_Count

and it also provides the following options to the users 'Show Faces','Width','','Font ', 'Color Scheme'.
If you click  on like button. It will  show a pop up for login only if your not logged in before. As soon as you enter login credentials this link is posted on  your Face book ‘WALL ’  RECENT ACTIVITY   as liked link.


For more details 
Refer link...
http://developers.facebook.com/docs/reference/plugins/like