Random numbers in JavaScript

Posted by: Dino Espositos WebLog, on 07 May 2007 | View original | Bookmarked: 0 time(s)

The Microsoft AJAX Client library serves you a so rich JavaScript language that it doesn't even look like a script language. In this regard, it makes it almost natural to think new functionalities in terms of classes. For example, random numbers. Here's a quick class to mimick the behavior of the managed Random class:// // Samples.Random :: //     Generates random numbers //// Define the namespace of the classType.registerNamespace('Samples');// ConstructorSamples.Random...

Advertisement
Free Agile Project Management Tool from Telerik
TeamPulse Community Edition helps your team effectively capture requirements, manage project plans, assign and track work, and most importantly, be continually connected with each other.
Category: Ajax | Other Posts: View all posts by this blogger | Report as irrelevant | View bloggers stats | Views: 791 | Hits: 44

Similar Posts

  • What’s Wrong With This Code (#23) more
  • Custom Panels in Silverlight/WPF Part 4: Virtualization more
  • My first asp.net website. more
  • A Lightweight Event Framework in JavaScript more
  • Inserting Many to Many Relationships in EF with or without a Join Entity more
  • Streaming Random Numbers for Effective Filtering more
  • Client Rendering Views with Spark and ASP.NET MVC more
  • YAPES: Problem Seven, Part 2 more
  • Custom JSON Serialization in ASP.NET AJAX more
  • JSON Serializers in .NET - not there yet more

News Categories

.NET | Agile | Ajax | Architecture | ASP.NET | BizTalk | C# | Certification | Data | DataGrid | DataSet | Debugger | DotNetNuke | Events | GridView | IIS | Indigo | JavaScript | Mobile | Mono | Patterns and Practices | Performance | Podcast | Refactor | Regex | Security | Sharepoint | Silverlight | Smart Client Applications | Software | SQL | VB.NET | Visual Studio | W3 | WCF | WinFx | WPF | WSE | XAML | XLinq | XML | XSD