Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / December 2007

Tip: Looking for answers? Try searching our database.

ajax updating a table not using updatepanel?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
soni2926@yahoo.com - 05 Dec 2007 20:10 GMT
hi,
we currently have a site done using asp.net 2.0, one of the pages has
a datagrid, which displays some information. currently there is a
refresh button, but we want to change this so that every few secs we
can refresh it using ajax.  using javascript to call the webservice,
we're not using updatepanels.  once the webservice returns its's
results, as a dataset, how do we populate the table?  I've done things
before updating labels and textboxes, but with tables...do we just add
a row using javascript to it?
bruce barker - 05 Dec 2007 20:54 GMT
yes. the browser dom api is close to xml dom api. you create nodes. basically
you create a tr nodes, and td nodes. and set the innerHTML. you can alsso
update the table in place, adding or deleteing the extra rows.

not sure why you don't use an update panel. it just does an ajax call which
returns the html and sets the inner html.

you could also have the webservice return the html and do it yourself.

in any case if you do a 2 sec refresh with ajax you will need to test for
memory leaks with IE, and fix your code. be sure to read the dom leak section:

  http://msdn2.microsoft.com/en-us/library/bb250448.aspx

-- bruce (sqlwork.com)

> hi,
> we currently have a site done using asp.net 2.0, one of the pages has
[quoted text clipped - 5 lines]
> before updating labels and textboxes, but with tables...do we just add
> a row using javascript to it?

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.