C# web application w/ ASP.net

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

hi,

This is my first time developing a web app in asp.net web application using
C#. All examples i see are web applications with buttons so i didnt have much
of a problem displaying text and images to the page because the button_click
does a part of the reloading (refreshing) of the page.

This is my problem now, im developing a web application that listens to the
sever and everytime it recieves a message, the message is displayed and a
certain image is changed to another image. Here's the thing, since i dont
have a button or anything to press which means the page wont be realoading,
how can i display the messages in the page and change images without any
buttons or should i force a reload? I really dont have any idea on this one..
can anyone suggest, give ideas or sample source? I would really really be
very thankful.


Regards,
Stan
 
Since this question has absolutely nothing to do with the C# programming
language, I'd suggest you to try to post to
microsoft.public.dotnet.framework.aspnet instead where you'd have better
chance to get accurate response.
 
Dear Lebesgue,

PLease read my question first before making any conclusion and replying to
my post. My code are all in C# and it is developed in asp.net web application
USING C#. please be more careful next time as you are discouraging others to
answer to this post. Thank you.
 
Dear Rain,

you seem to absolutely misunderstand the boundary between language,
library and framework. I, and others in this group would gratefuly explain
the differences to you, but your harsh comments discourage me from doing
that. You don't want to post your ASP.NET question to ASP.NET group - your
problem.

Have a nice day.
 
Web apps are stateless, this means it has no actual connection to the
server - so there is now easy way for the server to tell your application
that something has changed. HTTP issues a request from the browser, and the
server sends a response - end of story really.

Without a formal refresh of the page your web page wont know something on
the server has changed - that said, you dont have to refresh all of the
page, you could use Ajax or Atlas to refresh only a DIV for example. Take a
look at these examples to and see if it helps.

http://www.devx.com/webdev/Article/28451
http://www.mousewhisperer.co.uk/ajax_page.html

Also worth noting that without having to push buttons, you can do a good old
fashioned meta refresh of the page after a certain time.

Regards

John Timney (MVP)
 
Thanks John, il try it. Thanks for the response.

John Timney (MVP) said:
Web apps are stateless, this means it has no actual connection to the
server - so there is now easy way for the server to tell your application
that something has changed. HTTP issues a request from the browser, and the
server sends a response - end of story really.

Without a formal refresh of the page your web page wont know something on
the server has changed - that said, you dont have to refresh all of the
page, you could use Ajax or Atlas to refresh only a DIV for example. Take a
look at these examples to and see if it helps.

http://www.devx.com/webdev/Article/28451
http://www.mousewhisperer.co.uk/ajax_page.html

Also worth noting that without having to push buttons, you can do a good old
fashioned meta refresh of the page after a certain time.

Regards

John Timney (MVP)
 
Dear Lebesgue,

Please do explain, i insist. I really want to know how my question has
absolutely nothing to do with C# programming so next time i wont be posting
it here if ever im convinced.
 
Back
Top