|
Simple Ajax example using MagicAjax |
|
Saturday, 25 November 2006 |
|
MagicAjax.NET is an open-source framework designed to make it easier and more intuitive for developers to integrate AJAX technology into their web pages, without replacing the ASP.NET controls and/or writing tons of AJAX javascript code.
This example shows how to multiply two TextBox values and put the result in the third TextBox using AJAX. More information and application download in: www.magicajax.net Steps:
# 1- Download the MagicAjax AJAX framework from www.magicajax.net # 2- In Visual Studio->WebSite->AddReference add a new reference to MagicAjax.dll that you downloaded. (Click in browse then search for the MagicAjax.dll file in the MagixAjax bin folder) # 3- Put this in the beginning of web.config file before appSettings tag: <configSections> <section name="magicAjax" type="MagicAjax.Configuration.MagicAjaxSectionHandler,MagicAjax"/> </configSections> <magicAjax outputCompareMode="HashCode" tracing="false"> <pageStore mode="NoStore" unloadStoredPage="false" cacheTimeout="5" maxConcurrentPages="5" maxPagesLimitAlert="false"/> </magicAjax> # 4- The put this inside the system.web tag: <httpModules> <add name="MagicAjax" type="MagicAjax.MagicAjaxModule, MagicAjax"/> </httpModules> Now you are ready to use MagicAjax! Lets continue: |
|
Last Updated ( Tuesday, 28 November 2006 )
|
|
Read more...
|
|
|
Sunday, 05 November 2006 |
|
This code example shows how to store objects in the Session object ins ASP.NET.
You don't really need to remove objects from Session object because it only lasts during the session lifetime. However, you can remove objects by using the Session.Remove() method or the RemoveAll() method. You might want to use these two methods to conserve Web server resources, especially if you store large objects in Session. (Code in C#)
/// Saving a string to Session key 'customer'. string customerName = 'JoeSmith'; Session.Add("customer", customerName); /// Retrieving the session object. string customerName = (string)Session["customer"]; |
|
Last Updated ( Friday, 08 December 2006 )
|
|
|