Updating text on a webpage
Before we delve into the details of updating the screen and page title with the currently logged on user's open work item count, let's first take a high-level look at the solution.We need some way for the page to contact the server and ask, "How many work items are open for the currently logged on user?The remainder of this article shows how to implement such functionality using the ASP.NET AJAX framework, script-enabled Web services, and a touch of Java Script.
She will see the message, "3 open work items" in the upper left corner of the screen.
A better solution is to use AJAX to interactively refresh the text in the upper left corner.
And if the Java Script that updates the text also updates the page's title to include the number of open work items the user can see the number of current open work items in the task bar when the browser is minimized.
NET AJAX framework, script-enabled Web services, and a few lines of Java Script, building upon the techniques discussed in Retrieving Server-Side Data Using Web Services.
A complete, working demo is available for download at the end of this article. The download available at the end of this article includes a demo illustrating the concepts touched upon in this article.