Dec 19
[Disclaimer: I’ve received a free copy of this book from O’Reilly] I’ve finally managed to finish reading Ian Griffiths’ last book (yep, it’s a big book!) and I can tell you that it’s a great piece of work. In a similar vein with Jeffrey’s CLR via C# (I’ll be writing a review about this in […]
Read the rest of this entry »
Nov 15
Today’s post presents a quick tip: if you’re interesting in measuring the performance of your web app (also applicable to Windows Store apps written in JS), then don’t start it by hitting F5 in VS. IF you start your app in debug mode, your JS code won’t be JITed and the results will be different […]
Read the rest of this entry »
Nov 13
I’ve ended the previous post on numeric conversions talking about overflow and how it might surprise you from time to time. For instance, here’s an example that might get you off guard: uint a = uint.MaxValue; int b = (int)a; Console.WriteLine("{0} – {1}", a,b);//-1 Running the previous snippet ends up printing the following: 4294967295 – […]
Read the rest of this entry »
Nov 12
If you’re a regular reader of this blog, you’ve probably noticed the problems I’ve been getting recently when I insert code snippets in my posts: When I write technical posts, I use Windows Live Writer because it’s free and it has lots of plugins. To be honest, it simply rocks! Now, I’ve used several formatting […]
Read the rest of this entry »
Nov 12
Conversions…such a boring topic and I’m positive that you already know everything there is to know about numeric conversions in C#. That’s all good, but I think there might be some small details that might bite you if you’re not careful. Ok, let’s start with the basics, shall we? Everyone knows that whenever you need […]
Read the rest of this entry »
Nov 05
Images are probably the most used media type in a page. Here are some simple suggestions for improving the performance of a page that uses images: include images in its native size. Do not resize the image by using the width and height attributes of the img tag (or its equivalent CSS properties). If needed, […]
Read the rest of this entry »
Oct 31
Ok, so here’s the deal: I’ve just finished up installing the windows phone 8 SDK. Now, the deal killer: in order to run it, the BIOS needs to support hardware assisted virtualization, second level address translation (SLAT, aka EPT in Intel processors) and hardware based data execution prevention. And of course, you must be running […]
Read the rest of this entry »
Oct 28
After publishing my latest post, I’ve received a couple of emails from fellow readers asking me if I didn’t mess up things when I’ve mentioned Undefined. Shouldn’t it be undefined? And the answer is no, I didn’t make an error because I was talking about types (and not about values). This kind of detail is […]
Read the rest of this entry »
Oct 21
[This is an opinion article about taxes in Portugal for 2013 and that’s why it’s entirely written in Portuguese. If you’re not living in Portugal, then it’s safe to carry on reading other stuff] Durante este fim de semana, tive a oportunidade de me aperceber que ainda há pessoas que acreditam no pai natal (ou […]
Read the rest of this entry »
Oct 21
After publishing my previous post, I’ve received some questions from friends which make me believe that I probably need to elaborate further on my “what is an object in JavaScript thesis”. So be it. If you’ve read the previous post, you probably remember me writing this: “In JavaScript, you can think of objects as being […]
Read the rest of this entry »
Oct 18
By now, I think there’s no doubt about how important JavaScript is. And that’s why I thought it would probably be a good idea to write a little bit more about it. By doing it, I’ll refresh my memory and I’m also hoping to learn one or two new things that I might have missed […]
Read the rest of this entry »
Oct 09
While I was catching up on my blog roll, I’ve noticed that my friend Alberto ended up being surprised by another nitpick difference between C# and VB.NET which does not help the programmer which needs to be proficient in both languages. Here’s the culprit code (in VB.NET and then in C#): Dim x as Integer […]
Read the rest of this entry »
Oct 03
IIS 8 introduces a new feature known as application initialization which allows you to present static content (ex.: an HTML page) while the application is completing its initialization tasks. In other words, with IIS 8, you can set an HTML page which is returned to the user while the application is “warming up”. To use […]
Read the rest of this entry »
Oct 01
I’ve just noticed that MS has presented me again with an ASP.NET MVP award. I really wasn’t expecting this…thanks MS!
Read the rest of this entry »
Oct 01
[Disclaimer: I’ve received a review copy of this book from O’Reilly] I’ve been searching for a good regular expression book for some time and I think I’ve finally found one which fits my requirements. Regular Expressions Cookbook is really a great book and you can use it as a reference for quickly picking up one […]
Read the rest of this entry »
Sep 27
In these last couple of days I’ve been busy trying to refactor some apps which are starting to show their age. It hasn’t been fun because unfortunately I didn’t have a high enough code coverage to perform the refactoring safely (oh well, life sucks sometime!). Even though it’s not the most pleasant thing to do […]
Read the rest of this entry »
Sep 24
If you’re a long time user of ASP.NET, you’re probably aware that the out of the box providers have some limitations. For instance, you couldn’t really use them with an SQL Compact database because they depended on stored procedure support for performing their actions. Besides that, clean up and maintenance in general depended on agents […]
Read the rest of this entry »
Sep 22
Until now, it was common to see this pattern in our views: <script src="@Url.Content("~/scripts/myscript.js")"></script> The Content method is a helper method which is responsible for converting a relative path into an absolute path. From now on (where now is the MVC4 release date which happened sometime ago ), we can simplify our code so that […]
Read the rest of this entry »
Sep 20
One of the things that I needed to do in the past was to write a cross-platform project which had to be consumed from Silverlight and an ASP.NET MVC project. At the time, I was kind of lucky because you could reuse a Silverlight assembly in a .NET project provided that you only used some […]
Read the rest of this entry »
Sep 20
Oh, and yes, I’m still alive and kicking ! (thanks for asking ) In these last couple of months, I have really been really busy trying to finish up the Windows 8 and ASP.NET 4.5 Web Forms books (yes, at the same time ). I’m pleased to tell you that both books have entered their […]
Read the rest of this entry »
May 31
Today, I’ve started getting another license error. I’ve tried to open a project I’ve built a few weeks ago and when I’ve hit F5, it simply redirected me to the store and shown me the following message: Wtf? Another lic problem? why me?? Fortunately, I wasn’t alone in this one and I’ve found this post […]
Read the rest of this entry »
May 18
Once more, released by FCA and in Portuguese! It covers ASP.NET MVC 2, 3 and 4 (this release presents the new stuff introduced by the current beta). Btw, I should also mention that if anything changes from beta to RC or RTM, you’ll be able to get the updated info from the FCA site. Hope […]
Read the rest of this entry »
May 07
As you know if you read this blog, I’ve been unable to write any Metro JavaScript code for a few days because I couldn’t renew my developer license. Well, after complaining in the forums, I had the good fortunate to receive some attention from Mike Wong, who was kind enough to take this problem with […]
Read the rest of this entry »
May 03
This is simply unbelievable! As an early “Win 8 dev adopter”, I’m really stumped with the error I’m getting for the last couple of days. Being an early adopter means getting all sort of problems and being subject to changes which breaks everything you’ve written with the previous release. Sometimes, it’s not fun, but I […]
Read the rest of this entry »
Apr 19
I’ve been so busy in these last months that I’ve almost missed the release of the 2nd edition of my HTML5 book. I’ve added a new chapter on SVG and I’ve also added several new sections and examples to the existing chapters which illustrate how you can combine the new features introduced by HTML5 to […]
Read the rest of this entry »
Mar 28
In these last days, we’ve finished moving an existing web site to a new server which was running IIS 7.5. This site had an upload service which used streaming for allowing the upload of some interestingly sized files. We’ve already had it running without any problems in IIS 6 and 7 (though in this case, […]
Read the rest of this entry »
Mar 09
It took me some time, but I finally managed to get the concepts of local vs. web contexts. It took some time not because they’re that difficult, but because the Windows 8 Metro docs are still a mess (which is understandable, since we’re still at beta – pardon me, I mean Consumer Preview) and finding […]
Read the rest of this entry »
Mar 06
Pedro Perfeito’s MS SQL Server 2012 Integration Service’s book is now available for pre-order from Packt. If you’re looking for a good reading in this area, then this is probably a book you should consider.
Read the rest of this entry »
Jan 27
If you’ve been doing Web development from some time now and you’ve looked at several of the Windows 8 samples, you’re probably wondering which event you should handle if you’re interested in doing work as soon as you can. The first option you have is to handle the DOMContentLoaded event. As you probably know, this […]
Read the rest of this entry »