Buy Questpond's video subscriptions on
huge discount
.
Online: 7177
Home
Articles
Interviews
Forums
For Beginners
Popular Questions
ITIL Career Advice
PMP Career Advice
Career Advices
Codes
Videos
ASP.NET
ASP.NET MVC
Android Intel XDK
Sql Server
AngularJS
Bootstrap
Backbone.JS
MongoDB
LESS (CSS)
jQuery
WPF
WWF
SSIS
LightSwitch
Tutorials
News
ASP.NET MVC
|
Be Interview Ready
|
Top Performers
|
DNF MVP
|
Top Posts
|
Winners
|
Subscribe
|
Catalogs
Welcome Guest !
Register
Login
Home
>
Forums
>
ASP.NET
>
Loading ...
EnableViewState property of label [Resolved]
Posted by
Surajemo
under
ASP.NET
on 1/12/2012 |
Points: 10
| Views : 5804 | Status :
[Member]
| Replies : 10
Write New Post
|
Search Forums
|
Resolved Posts
|
Un Answered Posts
|
Forums Home
what is EnableViewState and EnableTheming property of label what does it do if we make it True Or false
can someone please help me out in understanding this propertys of label.
[Resolved]
Reply
|
Reply with Attachment
Alert Moderator
Responses
Posted by:
Surajemo
on: 1/12/2012
[Member]
Starter
|
Points: 25
0
got it
i understood the concept
thanks :)
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Ogipansrk
on: 1/12/2012
[Member]
Starter
|
Points: 25
0
Surajemo,
EnableThemeing
property indicates whether themes are enabled for this control or not.
EnableViewState property
: Regarding this , first you need a have a better understaning of what is "VIEWSTATE".
pls refer this url for better knowledge by MSDN : http://msdn.microsoft.com/en-us/library/bb386448.aspx
Regards,
Ogipansrk
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Vuyiswamb
on: 1/12/2012
[Member]
[MVP]
[Administrator]
NotApplicable
|
Points: 25
0
ASP.NET is another form of html and it is stateless , which means if a a postback can occur, you will look selection on your combobox , listbox or the value that was selected will be lost. So there is a Property named "ViewState" it is another form of persistence , which means it help you to persist or keep the changes after the post backs.
and EnableThemeing has been well explained by Ogipansrk
Thank you for posting at Dotnetfunda
[Administrator]
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Surajemo
on: 1/12/2012
[Member]
Starter
|
Points: 25
0
i went through that url it is kind of confusing
can u please explain this with an small example :)
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Ogipansrk
on: 1/12/2012
[Member]
Starter
|
Points: 25
0
Surajemo ,
Let me explain this in simple terms.
Step1: Take a new Webform.
Step2: Place Two Labels and Make its text property to empty.
Step3: Place a Button and Click on it. It will generate some code.
Step4: Now for one of the label make the property
ViewStateEnabled="Disable"
and Another as
Enabled
.
Step5: In Page Load , Set Text Property of two labels to some text.
Step6: Now run you application.
Step7: See the difference before and after clicking the button.
Regards,
Ogipansrk
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Surajemo
on: 1/12/2012
[Member]
Starter
|
Points: 25
0
no change
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Surajemo
on: 1/12/2012
[Member]
Starter
|
Points: 25
0
whatever i had written in the load event for the labels ie textproperty is being showed even if i clicked on the button still no change same out put is being displayed
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Ogipansrk
on: 1/12/2012
[Member]
Starter
|
Points: 25
0
I Understood wat u r doing.
Write the code in not ispostback mode like below:
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
Label1.Text = "Hello world!";
Label2.Text = "Label2";
}
}
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Muhsinathk
on: 6/12/2012
[Member]
Bronze
|
Points: 25
0
http://msdn.microsoft.com/en-us/library/system.web.ui.page.enableviewstate.aspx
http://stackoverflow.com/questions/448719/asp-net-enableviewstate-when-why-on-what-control
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Posted by:
Mankuji
on: 12/6/2014
[Member]
Starter
|
Points: 25
0
Step1: Write the code in EnableViewState.aspx.
Step2: Run the application
Step3: After click on Check button.
For full solution see this:
http://www.mindstick.com/blog/683/EnableViewState%20in%20ASP%20NET
Surajemo
, if this helps please
login
to
Mark As Answer
. |
Alert Moderator
Login to post response
Latest Posts
How to get the exact property name while getting error
(0)
PDB file is not showing Line Number in dot net application hosted on server
(0)
Both Strings morethan 5 letters in length end of the words one vowel and one consonent is different
(0)
how to check Any adjacent letters transposed between two strings(ex: JOHN, JHON)
(1)
can't receive data after success login ?
(1)
Implement Multi-Tenant in Azure Logic Apps
(0)
Why ASP.Net Core 7.0 Web API showing as Connection refused?
(0)
Iterating over columns of dataframe and print as rows in Python Django
(0)
More ...