473,397 Members | 2,056 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.

Ajax or just javascript

ton
Hi,

I wander what to do. I'm developing a webapplication. One of the parts is to
show records from a database.
To modifiy a value, text of relational link or date I would like to use Ajax
where possible. I saw the posiibilty of the Ajax control toolkit with the
calendar extender.
How nice. But is it fast? Thats the question, because the roundtrip to the
server would build the full page in postback and only the changes will be
posted back to the client. But it still is a full "renew" of the entire
page.
So my question is:

What is the advantage of using these controls, is it really faster, or is
there another way (javascript) to get a small calendar when the date-field
got the focus.

Please comment of better help me if you can

Thanx in advance
Ton

Jun 27 '08 #1
4 1481
"ton" <to*@nospam.nlwrote in message
news:14**************************@cache3.tilbu1.nb .home.nl...
What is the advantage of using these controls, is it really faster, or is
there another way (javascript) to get a small calendar when the date-field
got the focus.
Ajax is superb technology. However, that does not mean that it must be used
for every eventuality...

The calendar example is a good one. I have a JavaScript calendar which I've
used for years. It does everything I require of it, namely to display a
month at a time and to respond to mouse clicks. While the user is scrolling
backwards and forwards through the months there is no roundtrip to the
server at all. When the user chooses a date, I can add the date to a DOM
control or cause a postback if I want to. I can even persuade it to call a
server-side C# function via Ajax. The only time I might want it to retrieve
data from the server is when the client requires more functionality that
this e.g. they might want to display public holidays in a different font or
colour or whatever. Then, the calendar control would need server-side
connectivity, almost certainly through Ajax.

You are correct that Ajax callbacks are not so "heavy" as full postbacks,
but they do still involve a roundtrip to the server.

It's always been my belief that one of the simplest ways to improve a web
application's performance is to minimise the roundtrips to the server.

So, I would say that if it can be done client-side with JavaScript, then do
it client-side with JavaScript. This applies especially to things like
validation - e.g. there is absolutely no requirement whatever to validate
the contents of a numeric-only TextBox server-side...

I'd also advise you to have a serious look at Silverlight - some of the
possibilities with that technology are bordering on the revolutionary...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Jun 27 '08 #2
ton
thank you. It is just what I had in mind. Ajax but not for everything

can you tell me what calendar control you use? And is it hard to implement
it on VB.NET websites?
Or better can it be used in a web server control, because I've allready
developed a webserver control which displays te record of a table in 2
columns. To modifiy a date field the user has to type the date and I want to
chenge this by using a ajax or javascript control.

thanx

Ton

"Mark Rae [MVP]" <ma**@markNOSPAMrae.netschreef in bericht
news:%2******************@TK2MSFTNGP02.phx.gbl...
"ton" <to*@nospam.nlwrote in message
news:14**************************@cache3.tilbu1.nb .home.nl...
>What is the advantage of using these controls, is it really faster, or is
there another way (javascript) to get a small calendar when the
date-field got the focus.

Ajax is superb technology. However, that does not mean that it must be
used for every eventuality...

The calendar example is a good one. I have a JavaScript calendar which
I've used for years. It does everything I require of it, namely to display
a month at a time and to respond to mouse clicks. While the user is
scrolling backwards and forwards through the months there is no roundtrip
to the server at all. When the user chooses a date, I can add the date to
a DOM control or cause a postback if I want to. I can even persuade it to
call a server-side C# function via Ajax. The only time I might want it to
retrieve data from the server is when the client requires more
functionality that this e.g. they might want to display public holidays in
a different font or colour or whatever. Then, the calendar control would
need server-side connectivity, almost certainly through Ajax.

You are correct that Ajax callbacks are not so "heavy" as full postbacks,
but they do still involve a roundtrip to the server.

It's always been my belief that one of the simplest ways to improve a web
application's performance is to minimise the roundtrips to the server.

So, I would say that if it can be done client-side with JavaScript, then
do it client-side with JavaScript. This applies especially to things like
validation - e.g. there is absolutely no requirement whatever to validate
the contents of a numeric-only TextBox server-side...

I'd also advise you to have a serious look at Silverlight - some of the
possibilities with that technology are bordering on the revolutionary...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net
Jun 27 '08 #3
"ton" <to*@nospam.nlwrote in message
news:24**************************@cache3.tilbu1.nb .home.nl...

[top-posting corrected]
>The calendar example is a good one. I have a JavaScript calendar which
I've used for years.
Can you tell me what calendar control you use?
It's one that I wrote myself based on several that I found on the Internet,
all of which did part of what I wanted...
And is it hard to implement it on VB.NET websites?
I've never tried it with VB.NET as I never use that but, as I said, it's
pure client-side JavaScript so the server-side language is irrelevant...
Or better can it be used in a web server control
As above...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Jun 27 '08 #4
ton
thanx

ton

"Mark Rae [MVP]" <ma**@markNOSPAMrae.netschreef in bericht
news:eR**************@TK2MSFTNGP03.phx.gbl...
"ton" <to*@nospam.nlwrote in message
news:24**************************@cache3.tilbu1.nb .home.nl...

[top-posting corrected]
>>The calendar example is a good one. I have a JavaScript calendar which
I've used for years.
>Can you tell me what calendar control you use?

It's one that I wrote myself based on several that I found on the
Internet, all of which did part of what I wanted...
>And is it hard to implement it on VB.NET websites?

I've never tried it with VB.NET as I never use that but, as I said, it's
pure client-side JavaScript so the server-side language is irrelevant...
>Or better can it be used in a web server control

As above...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net
Jun 27 '08 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: bobzimuta | last post by:
I'm creating a simple AJAX library. It's an object that will return an array containing the response text or xml. I'm trying to find a way to assign the response as a property of the object, but...
0
by: melledge | last post by:
Ajax Developers' Day added to XTech 2006 agenda XTech 2006 - 17-19 May - Hotel Grand Krasnopolsky - Amsterdam, The Netherlands
5
by: darrel | last post by:
I've been playing with prototype.js and scriptaculous to create some nice drag-and-drop interaction on my applications GUI. That's working well. Now I want to take the next step and start passing...
5
by: dougwig | last post by:
I'm trying to handle the scenario where a user's session times out and and their ajax request triggers a redirection by the webserver (302 error?). I'm using Prototype 1.4 and the my works great...
31
by: Tony | last post by:
I just noticed that prototype.js is one of the files in the Ajax.NET distribution - I'm pretty concerned about this. Does anyone know if this is the same "prototype.js" that is not well-liked...
1
by: geevaa | last post by:
http://www.phpbuilder.com/columns/kassemi20050606.php3 XMLHttpRequest and AJAX for PHP programmers James Kassemi Introduction: Although the concept isn't entirely new, XMLHttpRequest...
17
by: Arjen | last post by:
Hi, I want to reload 2 divs at one click. Ive tried: <a href = "javascript:void(0);"...
0
by: Tarik Monem | last post by:
I have been working on an all AJAX/DOM web site which is set to go live today and I thought I'd share my discoveries with all of you whom have helped me when I have encountered different issues along...
8
by: Bill Gower | last post by:
I have a webapp that uses the AjaxControlToolkit. The app and ajax works fine when run within my dev server in Visual Studio 2005 but does not work on IIS. Any Suggestions? Bill
6
by: Bart Van der Donck | last post by:
Hello, I'm presenting my new library 'AJAX Cross Domain' - a javascript extension that allows to perform cross-domain AJAX requests. http://www.ajax-cross-domain.com/ Any comments or...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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,...

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.