I need to develop a new asp.net 2.0 web app that has to allow a client the ability to work with an internal adviser on the same document (an offer) at the same time. I am not sure how to allow two persons working on the same application and changes be reflected to both browsers. For sharing the data, I could set up a DB, apply a unique ID that they both would use to manipulate the common data. The problem that I have is with the ASP.NET application, which I don't know how to build to allow two persons working simultaneously on a set of data and see instantly the changes the other person does.
Hope my explanation is clear :-) I would appreciate any help, comments, or suggestions.
Thanks.
Mikebrowsers don't an event model. you will ave to use a polling techinque. look
at an ajax library for this support. as you will be doing client script and
dhtml, brush up on html. i'd use the html controls and not the asp.net ones.
-- bruce (sqlwork.com)
Hi Bruce,
Do you have any additional information (links, blogs, etc.) on how to use a
polling technique? What about a timer on the server-side that pulls the data
and, through AJAX, sends it to the related browsers?
Thanks.
Mike
"bruce barker (sqlwork.com)" <b_r_u_c_e_removeunderscores@.sqlwork.comwrote
in message news:OSmLPRxtGHA.3552@.TK2MSFTNGP03.phx.gbl...
Quote:
Originally Posted by
browsers don't an event model. you will ave to use a polling techinque.
look at an ajax library for this support. as you will be doing client
script and dhtml, brush up on html. i'd use the html controls and not the
asp.net ones.
>
-- bruce (sqlwork.com)
>
>
Hi,
Mike wrote:
Quote:
Originally Posted by
Hi Bruce,
>
Do you have any additional information (links, blogs, etc.) on how to use a
polling technique? What about a timer on the server-side that pulls the data
and, through AJAX, sends it to the related browsers?
>
Thanks.
Mike
You still have it wrong. The server cannot send data to the browser
without being asked first. This is the request/response model. A
"normal" request or an AJAX request are not different for the server,
they must come first, and then only the server can answer them.
Polling is a mechanism where the client sends a request periodically to
the server. JavaScript has two built-in timer methods: One "single shot"
one and one periodical one:
http://developer.mozilla.org/en/doc...ndow.setTimeout
and
http://developer.mozilla.org/en/doc...dow.setInterval
Use these methods to send periodic requests to the server.
My preferate way is to send a request, then wait for the response (or an
error), then use setTimeout to start a timer. When the timer expires,
send the next request. Use config files to modify the polling delay.
HTH,
Laurent
--
Laurent Bugnion, GalaSoft
Software engineering: http://www.galasoft-LB.ch
PhotoAlbum: http://www.galasoft-LB.ch/pictures
Support children in Calcutta: http://www.calcutta-espoir.ch
0 comments:
Post a Comment