Archives
-
The Humor of Silverlight
-
Arrival to Redmond
In this year, I was rewarded as an MVP on C# of Year 2010; at the same time, 3 different groups of Microsoft offered me 3 SDE II positions, and I made my choice. Now, with the help of Microsoft, I just relocated from China to Redmond.
2 years ago, when I left Redmond, I decided that I’ll be back. Now everything just looks the same as 2 years ago. What a familiar place!
-
Microsoft Most Valuable Professional Kit Unboxing
I am very happy to receive the Microsoft Most Valuable Professional Kit:
-
Ellipses (…) In UI Command Text
Some times, command text is followed by ellipsis (…) or not:
For years, many developers told me that ellipses mean a new window or dialog will pop up. For example, here:
- Clicking New / Save / Exit will not pop up new window or dialog;
- Clicking Open… / Save As… / Page Setup… / Print… will pop up new window or dialog.
But this is not correct. Take a look at About Notepad.
-
A Snapshot Of ASP.NET Homepage
First time to appear on www.asp.net homepage as headline!
-
A ToDynamic() Extension Method For Fluent Reflection
Recently I needed to demonstrate some code with reflection, but I felt it inconvenient and tedious. To simplify the reflection coding, I created a ToDynamic() extension method. The source code can be downloaded from here.
-
Back From Microsoft Web Camps Beijing
I am just back from Microsoft Web Camps, where Web developers in Beijing had a good time for 2 days with 2 fantastic speakers, Scott Hanselman and James Senior.
On day 1, Scott and James talked about Web Platform Installer, ASP.NET core runtime, ASP.NET MVC, Entity Framework, Visual Studio 2010, … They were humorous and smart, and everyone was excited!
-
Anti-Forgery Request Recipes For ASP.NET MVC And AJAX
This post discusses solutions for anti-forgery request scenarios in ASP.NET MVC and AJAX:
- How to enable validation on controller, instead of on each action;
- How to specify non-constant token salt in runtime;
- How to work with the server side validation in AJAX scenarios.
-
Understanding LINQ to SQL (10) Implementing LINQ to SQL Provider
So far LINQ to SQL data CRUD (Creating / Retrieving / Updating / Deleting) has been explained. This post takes a deeper look at the internal implementation of LINQ to SQL query.
-
Understanding LINQ to SQL (9) Concurrent Conflict
Conflicts are very common when concurrently accessing the same data.
Conflicts in concurrent data access
The following code demonstrates the concurrent conflict scenario:
-
Understanding LINQ to SQL (8) Transaction
Database data Changing cannot be talked about without transactions.
Implementing TRANSACTION (BEGIN / COMMIT / ROLLBACK)
The previous post has shown that, when invoking SubmitChanges(), the translated SQL (INSERT / UPDATE / DELETE) are always executed within a TRANSACTION.
Internally, DataContext.SubmitChanges() invokes DataContext.SubmitChanges(ConflictMode.FailOnFirstConflict). The latter is implemented like this:
-
Where Is Transaction Events In SQL Server Profiler?
SQL Server Profiler does not monitor transaction events by default.
After installing SQL Server, when creating a new trace, the default template is “Standard”:
-
Understanding LINQ to SQL (7) Data Changing
-
Understanding LINQ to SQL (6) Working With Deferred Execution
-
Understanding LINQ to SQL (5) Remote And Local Method Call
-
Crazy Bug in Visual Studio 2010 RTM: Copy And Paste
The copy / paste functionality is very buggy in Visual Studio 2010 Beta and RC. In Beta sometimes this even cause Visual Studio crash. Now after using RTM for a week, I found the bug remains, and greatly affect the experience. I searched the Internet and found this comment from Microsoft:
-
Blog Code Font Change: From Courier New to Consolas
Courier New is an excellent monospaced (non-proportional) typeface introduced with Windows 3.1. As a UI designer, I cannot tell how many year I have worked with Courier New. As the release of Visual Studio 2010 and the new MSDN, Consolas becomes the default font of code.
-
Understanding LINQ to SQL (4) Data Retrieving Via Query Methods
-
Playing with the CPU Usage Curve
In the book “The Beauty Of Programming”, which talks about Microsoft interview questions, there is a interesting section: Control the CPU curve of Windows Task Manager.
-
The Volume In Windows Media Center
I developed a tool for Windows Media Center in 2008 in Redmond, and I got a very cool Windows Media Center remote controller. Since then I became a fun of it. Windows Media Center + remote controller makes my Alienware M17x into a powerful home theatre.
-
Understanding LINQ to SQL (3) Expression Tree
-
Understanding LINQ to SQL (2) IQueryable<T>
-
Understanding LINQ to SQL (1) Object-Relational Mapping
-
Naming in Visual Studio 2010 advertisement
A great advertisement for Visual Studio 2010 has been released. Click here to download.
-
Understanding LINQ to Objects (8) The Design Of IEnumerable<T>
-
Understanding LINQ to Objects (3) Iterator Pattern and foreach
[LINQ via C#] - [LINQ to Objects]
-
The protocol of AJAX
This is a true story. This morning I went to office by train of Beijing subway, and 4 developers were sitting next to me and talking about Web development and their Web product. After a while, someone asked an interesting question: What is the protocol of AJAX?
-
Introducing LINQ (3) Programming Paradigms
[LINQ via C#] - [Introducing LINQ]
-
Resolving The nvlddmkm.sys Blue Screen Issue
I started to use ATI discrete graphic cards since 2002. At the end of 2009, I got my first pair of NVIDIA cards, GTX260M SLI , and recently I after I upgraded the driver to the latest 195 release, I encountered the blue screen failure on my laptop with Windows 7.