Inline-Edit Control Using ASP.NET 2.0 AJAX 1.0 Extensions
page 2 of 7
by Bilal Haidar
Feedback
Average Rating: 
Views (Total / Last 10 Days): 34747/ 66

Original Script

The logic behind the inline-edit AJAX script that this article will discuss is based on a native AJAX script.

The author of that script used native AJAX to enable inline-edit on a web form. In this article we will convert that script into an AJAX 1.0 script where you place a reference to it inside the Script References section of the ScriptManager.

The basic idea behind the inline-edit control is that a span HTML control is placed on the Web form with a special class name. The inline-edit script will parse the page and get all spans with a specific class name and add to them onclick event. So when clicked, the content of the clicked span will be shown either in a Textbox or TextArea depending on the size of text to be edited.


View Entire Article

User Comments

Title: Glo Vapor Electonic Cigarette   
Name: Chris Fontan
Date: 2010-06-20 12:42:14 PM
Comment:
we used the inline edit in the admin section of our website! It works GREAT!


Electronic cigarettes, 510 ego, tornado, glo stick, ecigarettes, liquid nicotine, long battery life, smokeless cigarettes, healthy cigarette, water vapor, tobacco alternative, stop smoking, quit smoking
www.glovapor.com
Title: thanks   
Name: gasby
Date: 2010-04-09 12:27:13 PM
Comment:
the change does not reflect in the span when the page is refreshed
Title: Not Download   
Name: Adil
Date: 2009-06-11 2:53:58 AM
Comment:
I want to download this arttical but not going to download .please ckeck it.
This is very good idea.
Thanks
Title: using more than 1 region   
Name: Chris Fontan
Date: 2008-09-23 12:49:48 PM
Comment:
is there a little more information on using multiple editable regions?
Title: Cool one   
Name: Habiburahman Khaled
Date: 2007-11-03 3:16:36 AM
Comment:
Thanks great one.
Title: Updates   
Name: Mikhail
Date: 2007-10-18 5:26:01 PM
Comment:
As far as I can see (correct me if I wrong) you can only update one field at a time.

I think it will be much better is to have autimatically generated button , which loops through all the controls on the form and check the class. if class is editText, if submit the ajax update request to the update page and when update is done, then refreshes all controls.
Title: Good Idea   
Name: Worawut Boontan
Date: 2007-10-18 8:14:57 AM
Comment:
Thanks
very nice idea.
Title: Re:   
Name: Bilal Haidar
Date: 2007-10-07 2:21:56 AM
Comment:
Thanks guys, you are full of sense,
Hey check out another version of the above control. In fact this one was based on another script and adding it to a website requires some work, that is why I came up with a new control that is a server control and enables inline edit. I will soon have an article on it, check it out here:
http://bhaidar.net/cs/archive/2007/10/03/asp-net-2-0-ajax-inlineeditlabel-control.aspx

Hope you enjoy it!
Regards
Title: Very Very Cool!   
Name: Mohammad Azam
Date: 2007-10-06 11:39:09 PM
Comment:
Wow! thank is soooo awesome :)
Title: Nice   
Name: Steve
Date: 2007-10-05 4:39:07 PM
Comment:
Very cool!






Community Advice: ASP | SQL | XML | Regular Expressions | Windows


©Copyright 1998-2021 ASPAlliance.com  |  Page Processed at 2021-11-29 12:57:30 AM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search