Literal And Label Control

Difference Between Literal and Label in ASP

The mail difference is the way how the tags are rendered

<asp:Label….Text=”Hello World” ..> ==> <span >Hello World</span>

<asp:Literal…Text=”Hello World” ..> ==> Hello World

The next difference is that the labels can be associated for a certain control in the web forms.
On the other hand literals can be used to add plain English text or Html to the Document.

Hope you got the difference šŸ™‚

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s