Asp.Net controls not keeping state on postback

Upgraded an Asp.Net project from Visual Studio 2013 to Visual Studio 2015 and then updated Telerik Controls from Version 2015.1.401.45 to 2015.2.826.45 and noticed none of my dropdowns, treeview controls where keeping state on postbacks.  I was binding data to these controls as per normal, but on postbacks they where losing state, so the dropdowns where empty and the chosen items where obviously not being kept.

Checked my Web.Config and I still had sessionstate active:-

<sessionState mode="InProc" cookieless="false" timeout="30" />


After much scratching of head I had another look at web.config and compared against a version in source control that was working and noticed this little gem:-

<pages enableViewState="false">

      <controls><add tagPrefix="telerik" namespace="Telerik.Web.UI" assembly="Telerik.Web.UI" /></controls>


So looks like the upgrade either with telerik or Visual Studio added:-


After removing this my Asp.Net code worked again - phew!

Asp.Net Telerik RadAlert RadWindow change globalization language culture

Using Telerik excellent RadAlert within RadWindowManager in an Asp.Net Web Application and I need to translate my website into another language other than English.  So how do we change the RadAlert text on the buttons to be a different language depending on the users browser language settings?

For this I am using an Asp.Net Master Page and including both the RadWindowManager + RadScriptManager e.g.

Next create a Global Resources file for the default language (this case English) and also the language you are catering for (this case German):-

Change the MasterPage's code behind to associate the locatization file with the buttons:-

And that is it, so when a user runs your Web Application in a browser set to German it will now automatically change the buttons to the correct language for things like RadAlert.

Asp.Net Telerik RadGrid change globalization language culture

Using Telerik excellent RadGrid in an Asp.Net Web Application and need to translate my website into another language other than English.  In this case German so first download the resource file from Telerik currently located here:-

Global resources for RadGrid

Pop the file into App_GlobalResources folder or create one if you don't already have it:-

Here I am using the RadGrid.Main.resx (English) and (German - all versions)

Now it does seem to pick up the language setting of the users browser settings so just do the switch in code (normally under Page_Load:-

if (!IsPostBack)


RadGrid.Culture = System.Globalization.CultureInfo.CurrentCulture


Using Telerik WPF RadWindow as MainWindow

Thought I would blog about how to use the Telerik abortion pill video WPF RadWindow as a MainWindow when using Visual Studio 2012 and .Net 4.5 (but I presume it will work with other versions).

So change the MainWindow.xaml from:-




Now this works fine but I notice that we have no taskbar icon, bit strange as this is default with the standard WPF form.  

To add this you will need a new reference:-



Now we get the Taskbar icon back but it is the default WPF one so to add a custom one I added my own icon to a new Resource file and then referenced it:-


I also want how to get the pill the icon to show in the WPF window itself.  So I add the following:-


     <Image Source="Resources/MyIcon.ico" Height="18"/>


I also want to add a Telerik style to the whole form so I just add in:-



The complete code looks like:-










    Header="My Telerik Form">    


        <Image Source="Resources/ReportsIcon.ico" Height="18"/>