Warning: strstr() expects parameter 1 to be string, array given in /f2/f9blog/public/wp-content/plugins/autoblogged/ab-functions.php on line 49
number - F9 Group Marketing and Technology Blog

F9 Group Marketing and Technology Blog

Marketing, Technology, and current news at http://www.f9group.com/

Entries Tagged ‘number’

Programmatically Set Decimal Places

It’s easy to programmatically set the number of decimal places in a decimal, float or double that is converted to a string.  Use the ToString method with the “N” argument summed with the number of decimal places: float value = 3.1415926F; int decimalPlaces = 3; string text = value.ToString( "N" + decimalPlaces ); Note that ‘decimalPlaces’ must be greater Related posts: C# Decimal: Literals, Conversions and Formatting Having Pun with C# In C#, a string is a String

Share and Enjoy:
  • Digg
  • Google
  • del.icio.us
  • Technorati
  • Facebook
  • MySpace
  • TwitThis
  • Blogsvine
  • description
  • E-mail this story to a friend!
  • Ping.fm
  • Print this article!
  • Slashdot
  • Yahoo! Buzz

Periodically Updating the Screen and Web Page Title with ASP.NET AJAX

Developers using Microsoft’s ASP.NET AJAX framework can efficiently and interactively retrieve data from the web server using the ASP.NET AJAX client API, a bit of JavaScript, and Web services that support script access. Last week’s article, Building Interactive User Interfaces with Microsoft ASP.NET AJAX: Retrieving Server-Side Data Using Web Services , looked at how to create such Web services and how to call them from an ASP.NET AJAX application. With a sprinkle of JavaScript, This functionality can be implemented to provide a user interface that periodically updates, presenting pertinent information to the user without the need for the user to refresh her browser. Consider the following scenario: you are building a website that serves as a front-end for a work item database. The database contains tasks assigned to an employee; throughout the course of the day new tasks may be assigned to an employee by other workers, by automated processes, or by other means. When an employee logs onto the site he sees a hyperlink that lists the number of open work items in the upper left corner of every page, and clicking that link takes him to a page that lists the open work items in his queue. After completing a work item he closes it, which removes it from his list of open work items. In a typical web application the number of open work items in the upper left corner would only be refreshed when the user performed a postback, manually refreshed the page, or visited a new page. Wouldn’t it be nice if that count of open work items would interactively update as new work items assigned to the user entered the queue? This article looks at how to build such an interactive user interface by using the ASP.NET AJAX framework, script-enabled Web services, and a few lines of JavaScript, 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. Read on to learn more! Read More >

Share and Enjoy:
  • Digg
  • Google
  • del.icio.us
  • Technorati
  • Facebook
  • MySpace
  • TwitThis
  • Blogsvine
  • description
  • E-mail this story to a friend!
  • Ping.fm
  • Print this article!
  • Slashdot
  • Yahoo! Buzz