473,397 Members | 2,033 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

loading data without a page refresh

hi all,
I am developing a web application related to the share market, what i want to accomplish is that i want to present the user share market data that will be updated every 40 seconds. but i dont want a page refresh do do that, i wanna do it the way it happens on say facebook, in which the page is updated with new contents without refreshing the page.

somebody suggested me to use AJAX to do so. can anyone give me a starting point to achieve that, may be through ajax or something else. a simple example will be highly appreciated.

a big thanks in advance..

Ather
Mar 22 '10 #1
2 5474
CroCrew
564 Expert 512MB
Hello athar258,

You can’t get away from some type of call back to the web server. I understand that you don’t want to refresh the entire page every 40 seconds too.

With that said… </ cough> AJAX UpdatePanel control </ cough>

Happy Coding,
CroCrew~
Mar 24 '10 #2
Frinavale
9,735 Expert Mod 8TB
I hate it when people say "I want my page to be updated with the most current information stored on the server but I don't want to make a request to the server".

It is impossible to get the data from the server if you don't ask the server for the data!

Ajax is made simple for ASP.NET developers.
Microsoft has created something called an UpdatePanel that helps you with this....so you pretty much don't have to learn Ajax in order to to perform an Asynchronous postback to the server.

This is how it works.

Anything in the UpdatePanel will cause an asynchronous postback to the server. So if you have a Button and a Label within the UpdatePanel and a bunch of content outside of the UpdatePanel...and the the user clicks the Button, only the portion of the page with the Button and the Label will be refreshed.

Please note that the whole page is sent to the page but when the request returns to the browser it is stripped down so that only the content within the UpdatePanel is sent back.

This means that you will have access to the controls outside of the UpdatePanel in your server side code....BUT...they will not be updated if you try to update them in an asynchronous postback.

So, my suggestion is that you place whatever you want to "refresh without posting back" in side an UpdatePanel so that you can postback without the user noticing.

Look up UpdatePanels.

-Frinny
Mar 25 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Darren Line | last post by:
Could someone kindly point me the direction of some sample script or tutorial that will enable me auto populate fields on a page. By this I mean, I have a page with address fields on it, they...
5
by: judiphuongtu | last post by:
I am trying to create an input form with a pull-down menu that allows a user to add an item to the pull-down. I don't want the page to refresh when I refresh the pull-down since there's entries on...
2
by: Arielle | last post by:
I've argued with this for quite some time and I've seen a number of other people on various other sites asking for this same thing with no answer so I figured that now that I have solved it I would...
1
by: PerumalSamy | last post by:
Hi, I had created asp.net page with checkbox control. I set autopostback property as true and i wrote codings inside checked changed of that checkbox to do some process . In runtime, while i clicking...
1
by: lakshmishri | last post by:
hi all can anyone answer this ?? i have developed a module which displays cricket score card and this is one of the part in a HTML page along with other modules. now this module alone must be...
8
by: m1post | last post by:
Hi, I'm very much a novice, and wondered if someone could help. I'll try to be as specific as possible, but don't waant you to have to read too much. I have 2 pages in the sequence. 1st allows...
5
onlymars
by: onlymars | last post by:
helloo guys, i have an image gallery page which have thumbnails at the bottom of the screen and the main image is in the middle of the page, i want that users click on the thumbnail pic's and the...
45
by: angelicdevil | last post by:
i have 2 tables 1 is status_type with field name status and other is users with field username and status now i want that the first listbox lists all status from status type ( this i have achieved...
1
by: rahullko05 | last post by:
one line code to replace an image without page refresh
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.