Archives
-
Wii (insert pun of your choice here)
I've finally been able to play the Nintendo Wii, and sure, I want one. I had decided not to buy yet another version of Mario Kart and that the new controller would not yield itself to most games, that it would only work for some very specific ones. After I've tried it, I still think that couldn't be my main gaming machine, but I want one anyway.
-
DevConnections '06 photos
Some photos from DevConnections (a.k.a. AspConnections)...
-
Eilon's class browser for the Microsoft AJAX Library
Back in the CTP days, Wilco wrote a nice class browser that has been used for a while by the ajax.asp.net documentation site.
-
DOM events in the Microsoft AJAX Library
In previous CTPs, the client-side DOM event model was the IE model. You would use attachEvent and get the event data from window.event. In other words, we had just implemented the IE model in Firefox and Safari. This didn't fly as well as we expected for a number of reasons. For instance, it wasn't very well received from a philosophical point of view: making standards-compliant browsers behave like the one non-compliant browser was interpreted by some as a malicious attempt by the Evil Empire to undermine the standardization of the Web by enforcing proprietary APIs. It wasn't. It just seemed at the time like a smart way to build cross-browser compatibility and the reason we did it this way and not the other way around is that both Safari and Firefox have extensible DOM Element prototypes whereas IE doesn't. In other words, there was no way we could make IE behave like the standard, but we could make the others behave like IE. Any other way to make a library cross-browser has to introduce a third API that abstracts the standard and proprietary APIs. This third API is of course just as proprietary as the IEism, whereas our previous approach had the advantage of not introducing a new one. Still, the implementation was fairly complex and relied on the presence of extensibility points that we had no guarantee we would find on other browsers that we may want to support in the future. Another problem with our first implementation was its reliance on the server to detect browsers and selectively send the compat scripts to the client. So we decided to change our compat layer and come back to a more conventional approach that will be easier to adapt to new browsers and that doesn't rely on the server, let alone on browser detection.
-
Dynamic languages in ASP.NET
David Ebbo wrote a very interesting article that explains in great details how they gave ASP.NET the ability to be driven by dynamic languages. The compilation system, on which David worked for a few years, is explained, as well as why it doesn't apply to dynamic languages. Then he goes on to explain how they were able to integrate IronPython anyway, taking advantage of an existing feature, no-compile pages.
-
Meet the team in Vegas next week
I'll be in Las Vegas next week for ASP Connections with some other people from the AJAX team. If you're going too, stop by and say hi.
-
ComponentArt on migrating to ASP.NET AJAX Beta 1
Miljan over at ComponentArt wrote his first post explaining how their migration to Beta 1 went (i.e. great, the whole thing was done in four days). He has some very nice things to say about the platform, which we're all very flattered about: "After getting over the initial hump, we found ASP.NET AJAX Beta 1 to be remarkably well functioning and stable."
-
Eilon on UpdatePanel changes
Eilon wrote two very helpful forum posts on the recent changes in UpdatePanel.
-
ASP.NET AJAX Beta 1 is out!
It's a great pleasure to announce the beta 1 of ASP.NET AJAX. It is a major release of the product formerly known as
PrinceAtlas. There are too many changes to enumerate here (we basically remodeled the house), but the idea is to provide a rock-solid core and continue to innovate with the value-add CTPs. I'll blog in the next few weeks on some of the new features, and the first one will be the compat layer, which has been completely redesigned based on your feedback. -
From closures to prototypes, part 2
In part 1 of this post, I exposed the differences between the closure and the prototype patterns to define JavaScript classes. In this post, I'll show the shortest path to convert an existing class built using Atlas and closures to a prototype-based class. I'll also show a few caveats that you need to be aware of.
-
From closures to prototypes, part 1
There are basically two ways to define classes in JavaScript: closures, where the constructor of the class both adds methods to the new instance and provides a common context for them, and prototypes, which are the first place JavaScript will look at when looking for a member that isn't directly defined on the instance. Don't worry if you don't understand everything I just said, I'll show and explain.
-
Careful with that prototype, Eugene
Here's one that could cost you some long and puzzling debugging sessions.
-
Deep thoughts on scientific research
Heard on France Inter the other day about scientific research funding (didn't catch the names of the authors of these quotes though):
-
A nice and compact way to coerce to Boolean in JavaScript
JavaScript is always the strange beast as far as comparisons are concerned. There are cases where the automatic contextual casting is not quite convenient. For example, we like to reliably return booleans from some of our methods, not null, not undefined and not some random object. Being able to say that this function will return a boolean is a Good Thing that the users of the API will appreciate when debugging.
-
ComponentArt releases Web.UI for ASP.NET AJAX
Atlas has its first commercial control library. Component Art just went live with the new version of their excellent control library. All their controls now have a full client-side API built on top of the Microsoft AJAX Library. They all support UpdatePanel and persist their changes across synchronous and asynchronous postbacks. The library already has full online documentation and live samples. They are certainly setting the bar very high for other component developers. To think that they were able to do that even though we're not even in beta is just amazing and just show the level of excitement around the technology.
-
Rick Strahl on ASP.NET AJAX
Rick has a very extensive post on his blog about the state of Atlas today. It's a fair and complete look at what the technology is today and what it will become in the next few months. The post is a great read that I personally enjoyed a lot because Rick is hard to please and well, he seems to be mostly pleased (which doesn't mean that we don't have a lot to do before we release, working on that).
-
And the real name of Atlas will be...
Scott just announced the naming and roadmap for Atlas going forward:
http://weblogs.asp.net/scottgu/archive/2006/09/11/_2200_Atlas_2200_-1.0-Naming-and-Roadmap.aspx -
Fixing the back button in Atlas
Nikhil has an excellent prototype that adds browser history management to UpdatePanel. The two things I like the most about this sample are the simplicity of the API and that it goes beyond just restoring the back button and bookmarkability.
-
What I understood in The Matrix Trilogy
(this is the translation of a French post I wrote in November 2004)
-
Will the Wii make you play less (and buy less games)?
Disclaimer: I work for Microsoft and have to admit I'm a big Xbox 360 fanboy so I will not be fully objective on this topic.
-
I'm not alone! (die, caps lock, die!)
It seems like I'm not alone in my hatred for useless keys.
-
Bragging rights
Here's my brain age:
-
Mixins for Atlas
I've beeen toying with that idea for a while and I thought I would try to get some feedback on it. Mixins are a way to dynamically add members to an existing object. I've built a small function, Type.Mixin, that does that by copying members from the mixin object's prototype to the object that you want to extend. The mixin object is a type (that is, a function) that can't be instantiated (you can ensure that by throwing from the constructor). The members that will extend the target object are defined on the prototype of the mixin.
-
Define undefined
We already knew that JavaScript had some issues with semantics. Here's another funny one. Guess what this code does:
-
Can you say "qwak"? OK, then fly.
This morning, I was at a language symposium that's taking place on the Microsoft campus. Many language gurus are there, Anders is doing the keynote, so it's definitely a place where you can learn a thing or two. Many of the talks are about dynamic languages and how to implement them in the CLR, and as usual, you can see the usual duck-typing quote on all slide decks:
-
Using the XmlDataSource Data property for easy samples
Here's a little trick to write samples that involves data binding controls to a database. It's very inconvenient to have to package a sample database with your code (especially when it's just a few lines of code in a blog), and just making sure your users have SQL Server installed is no small thing. All this just diverts the attention from what really matters: your sample code.
-
Nouvelle interview Atlas sur TV4IT
This post will be French only because it points to a French interview...
-
Best JavaScript blog award goes to...
I've decided to give awards today ;)
-
A slider client control for Atlas
Garbin has written a nice slider client control for Atlas and explains how he built it. Source code included.
-
The June CTP of Atlas is out
This new CTP is mainly bug fixes, but there are a few additions on UpdatePanel which should make your day if you've hit some of the caveats Matt and I talk about in our booklet on UpdatePanel.
-
NaN is a number
JavaScript, like .NET, has a special thing called NaN, which stands for Not a Number. It is useful to determine if parsing a string successfully returned a number or for some operation results. Well, guess what this evaluates to:
-
DotNetSlackers offers an MSDN Premium subscription for the best Atlas control or extender
The people over at DotNetSlackers are announcing a cool contest that can get you a free MSDN Premium subscription. Your control or extender has to be open-source and submitted before August 15. Good luck!
-
New book on UpdatePanel published by O'Reilly
O'Reilly is publishing my book on UpdatePanel. This is a short work (less than 60 pages) I did with Matt Gibbs that is scenario-focused and gives an in-depth look at the UpdatePanel control of ASP.NET "Atlas".
-
Script# brings compile-time and C# niceties to JavaScript development
I'm very excited to finally be able to point to this post of Nikhil's. I've known about this project from the start and am Super-Ultra-Mega-Excited (this expression (c) Andres Sanabria) about it, but until now I had to keep my mouth shut.
-
Tracing XmlHttp requests: an unobtrusive solution
To trace XmlHttp requests in your AJAX application, there are quite a few solutions. There's Fiddler, of course, and there is Nikhil's excellent browser helper. These solutions still have an important drawback: you have to install them and/or configure them.
-
Don't play this game
And I mean it. It will just eat up all of your free time. It will keep you awake at night and prevent you from doing anything else. For weeks. Or months. Your significant other will hate it.
Just look on the left of this page and compare my number of posts for April and May. Care to guess when I started playing The Game?
Don't start playing this game or you won't stop.
Oblivion -
GeoTagit: a great mashup made with Atlas
Try this:
-
ScriptDoc: document your Atlas classes
When I was talking at the Journées Académiques last week, someone in the audience asked me about documentation tools for Atlas classes. That was a great question, especially as I had such a tool ready...
-
.NET 2.0 Book recommendation
I've been meaning to do that for a while. A few months ago, I had the pleasure to review the ASP.NET 2.0 part of Patrick Smacchia's excellent Practical .Net2 and C#2. The book is really excellent and is the most complete I know on .NET 2.0. It covers with unparallelled accuracy everything about .NET 2.0. This book is an almost 900 page masterpiece and reference book that I highly recommend.
Practical .Net2 and C#2 -
Conference schedule for next week in France
I'll be in France next week for a series of conferences.
-
Visual Studio Express editions is now free (forever)
It's official: Visual Studio Express editions are now free to download and use indefinitely. That means that Visual Web Developer 2005 Express, Visual C# 2005 Express, Visual Basic 2005 Express, Visual C++ 2005 Express and Visual J# 2005 Express are completely free.
-
Did you mean: hgdgf?
I was testing the network connection on my laptop a few minutes ago and typed some random characters in Google (hgjhgk), just scrambling fingers on the keyboard. To my surprise, I got ten pages of results (of which this post will soon be part):
http://www.google.com/search?hl=en&q=hgjhgk -
XmlHttpRequest now a W3C standard
Contrary to what I said in my previous post, XmlHttp is now a W3C standard (draft):
http://www.w3.org/TR/XMLHttpRequest/ -
Let me explain one more time why the Atlas compatibility layer works this way...
It's the second time in just a few days that I see blog comments attack Atlas on its compatibility layer. I've tried to explain a few days ago why we made this design choice but I think it deserves an even more detailed explanation...
-
An Atlas TabStrip control based on the Accordion control
I love that. Kwang Suh sent me this new control he built a few days ago. From his own words:
-
Check out the new "Atlas" Control Toolkit
Shawn and his team just released a set of Atlas controls that you might want to check out. It contains some useful controls and extenders such as TextBoxWatermark or ToggleButton (I really like how this one is implemented because it's really using an HTML checkbox despite appearances which is the right semantics and makes it really transparent to use). The controls come with full source code that the license enables you to modify and use as you wish.
http://atlas.asp.net/default.aspx?tabid=47&subtabid=477 -
Atlas compatibility layer: why did we extend Firefox to implement IE-isms?
Microsoft does not enjoy the best reputation when it comes to respecting standards. So when seeing that Atlas has a compatibility layer that extends Firefox and Safari APIs to implement IE-isms, some have seen it as an attempt to discard the standard.
-
Mix06 demo part 2: building the accordion control
In the previous post, I've shown how to use the accordion control. Today, I'm going to explain how to build such a control. I'll try to give as much background as possible on the different patterns in this sample control. This article is going to be fairly technical, so please keep in mind that you don't need to know any of this to use the control. This post is mainly for people who want to build their own Atlas client-side controls.
-
Gaming 2.0
Think what you want about Web 2.0, it is an unescapable change in the way the web will grow in the future. It is the convergence of several emerging ideas and technologies that individually wouldn't mean as much but that taken together make a real difference. These ideas are (paraphrasing Wikipedia and isolating the technical points from the business ones):
-
Mix06 demo part 1: the accordion control
I thought I'd write a few posts about the controls I've created for Brad's Mix06 demo, which you can download from his blog:
-
XNA Framework
We’re not the only ones busy around here :). My friend Julien as well as other very smart people are building the next generation development system for Xbox and PC games, XNA. Part of this work is to build an implementation of the .NET framework for the Xbox 360. This means considerably reduced development costs for casual games and... who knows what's next? This is just going to be great as it's going to lower the entry bar for game development. I hope this is the return of the time when people like me, with the help of a few friends, could develop a reasonably successful game. This brings back 20-years old memories of the time when I was building video games with my friend Fabien for the TI99 and Atari 800...
-
Live from Mix 06
Mix is going really well. We have a much more diverse public here than at the usual Microsoft dev conferences. I've never seen that many Mac laptops at an MS conf. We're getting absolutely great feedback from attendees. Here's a sample from a conversation: "If you had told me two years ago that I would be at a Microsoft conference one day I would have just laughed at you, but this is great, it seems like you guys actually like us."
-
Ruby for .NET? This is going to be interesting...
There have been a few bridging projects in the past that aimed at using .NET libraries from Ruby. Now, this is different, this is an actual implementation of the Ruby language for the .NET Common Language Runtime. Seeing how .NET finally seems to be more than OK with dynamic languages (see the amazing IronPython project), this could prove to be a very interesting turn of events. The open-source project, initiated by the Queensland University of Technology in Australia, is in its early phases with only some of the standard Ruby libraries implemented. This is not very surprising as the most difficult parts of porting a language is usually that the language itself is not enough, you also need its base class library if you need more than a familiar syntax and if you want that to have more than marginal usefulness. J# suffers from the same kind of problem with its class library.
-
Did standards sterilize or enrich the web?
I know, I know, it is not very nice even to ask this question, especially coming from a Microsoftee. But really, I'd like to know what you think. We have had many discussions on this subject in the team and many of us have very sharply defined opinions one way or another.
-
Can tidal power plants have an effect on the Earth's rotation?
I just read an interesting article on the project to build power plants that tap into tidal energy. It's really weird to see that article now because I was discussing that exact subject with Fabien on the Stevens Pass chairs last Saturday.
-
Virtually drive through Seattle and San Francisco using Virtual Earth
They're at it again. They've added an amazing feature to Virtual Earth:
-
The duck's wake
This is the first translation I'm doing of one of my French science popularization blog posts.
-
More weird JavaScript: variable scope
I know I'm going to get "only a n00b would not know that" comments, but I'm sure this will help some folks out there, so here it goes.
-
Mix videos
I'll be at the Mix conference in Las Vegas in March.
-
Off-topic: An absolutely brilliant presentation
This is totally off-topic but this is a must-watch for anyone doing presentations in front of an audience. The contents is pretty interesting in itself (the concept of electronic identity) but the form of the presentation is what will blow you away. This is absolutely brilliant.
-
I love the Super Bowl!
We went skiing on Sunday (which was an especially well-named day this time) while everybody was eating nachos in front of the TV.
What a day! The snow in Stevens was perfect (14" of new snow in the last 48h), the sun was shining, I was in great shape and the resort was virtually empty.
Best skiing day this year, by far.
Couldn't there be several Super Bowls every year? Pretty please? -
Some insights about the development of Atlas behaviors
Nikhil has an excellent post about developing a client-side behavior with Atlas. If you're thinking about developing your own Atlas components, this is a must-read:
http://www.nikhilk.net/Entry.aspx?id=107 -
Some Atlas feedback
Karl wrote some feedback about the eWeek article:
-
Nice Atlas article in eWeek
-
I love Javascript!
Just kidding. But I think that got your attention :)
Seriously, there are things I really like about Javascript (like it being a dynamic language), but some things are just... So unexpected they just look plain wrong.
For instance, what do you think this evaluates to:
"" == 0
Of course, I gave you enough clues for you to guess that it does return the wrong thing. Yes, this is actually true. Empty string equals zero. Isn't that a beautiful feature? Isn't that going to make your life so much easier? No? Really? Well, I agree with you, this is FUBAR.
While I can understand that Javascript would evaluate both empty string and zero to be equivalent to false in contexts where a bool is expected, I would expect both sides of an == operator not to be such a place. To tell you the truth, I think it's kind of wrong even in boolean contexts because it's a bug attractor, but anyways.
If anyone has a reasonable explanation for this, I'm all ears.
Oh, and about a workaround... You can use toString() on both sides of the equals operator once you've checked that they are not undefined or null.
UPDATE: as some have pointed out in comments (and I should have researched that), you can use the strict equality operators (=== and !==) and get the expected results on recent browsers (on older browsers you can compare the types as well).
In a nutshell, I think the problem here is that the initial specification for the == operator was absolutely wrong, but changing it would have been a breaking change so they had to add the === operator to finally get it right. So for all useful purposes, I can see no reason to use == instead of === except to save one character. -
SiteMap menu with icons
While binding a Menu (or TreeView: everything in this article applies to TreeView as well) to a SiteMapDataSource is very easy, it can prove challenging to find how to extend the site map with custom properties and use these extended properties in a Menu. This sample shows how to add icons in a sitemap-driven menu.
-
Atlas interview on MSDN France
MSDN France publishes an interview they made of me in November. The subject is Atlas, but it's in French only. Thought some of you may find it useful anyway (and I don't get interviewed every day, so I thought I'd do some bragging).
-
Proof that there are Hitchhiker fans in the JScript UE team...
Here's an example I just found in the MSDN JScript documentation:
-
I made this faceplate
So here's what I've been up to. The original idea came from this beautiful Xbox 360 faceplate all the employees of the Xbox division got at launch.
It has some beautiful concept art but the best part in my opinion is this "I made this" thing they wrote on the USB door.
I figured that even though I was not working in the Xbox division, I could still have my own "I made this" faceplate.
I searched for a possible subject for my first custom faceplate and quickly settled on the Emily the Strange comic character. It has an excellent mood and both myself and my wife are great fans and collectors of Emily art and books. We love the elegance and simplicity of the bi or tri-color drawings and the way they're drawn with sharp edges and perfectly flat surfaces.
So what do you think? (except that it's not very personal, I just copied something I like, but well, let's say that I'm not too confident in my own drawing talent to do something really personal for the moment). -
My Xbox 360
Here's what my Xbox 360 looks like currently. Can you guess why?
UPDATE: Here's your feedback and my answers...
Azra: You add a tape recorder in?
BLR: Err, no, but that's an interesting hack idea. Certainly an original one...
Wim: Err...you decided to put a mod chip in? ;-)
BLR: Nope. No modchip exists yet, and there isn't much that a modchip would add to the unmodified 360. The feature set is already pretty cool and I'm not at all into piracy.
Wim: Problems with overheating?
BLR: No, I've never had any overheating problems. Both the box and its power brick have their vents away from any other object. I've never noticed one or the other being more than warm. If I had to modify something, it would be to put silent fans, because the built-in ones are pretty noisy.
Wally: Its turned the wrong way?
BLR: No, that's the front.
Wally: Its broken?
BLR: No, works perfectly.
Wally: You had laid it flat and had something on top of it?
BLR: No.
Brandon: looks like you spilled Tang on it and had to throw away the face plate.
BLR: Yes, I did remove the faceplate, but not for that reason. And I did "spill" something on the faceplate, but after I removed it.
Chris: Cause you got a new faceplate?
BLR: Aha! Getting close. But if I had bought a new faceplate, it would already be there. I still have only the original faceplate, but removed it for a good reason.
Travis: No, why? Tell me before I pick one up. Planning on it when they become available at the local Walmart.
BLR: go ahead and pick it up. It's absolutely awesome. Best console ever (and I've had a few). The Live feature is flawless.
Dror: i think you baought PS3 faceplate :)
BLR: :) That's a funny one.
Brian: You are painting your faceplate.
Chris: well that would mean you are customizing your faceplate. Cool.
You just inspired me, I think I may go paint my OEM faceplate this afternoon.
BLR: Yes, exactly.
I recommend acrylic paint and some varnish when it's dry.
I'll post pictures of the completed project once it's finished...