Archive for August, 2009
Undoubtedly you’ve heard of the app_offline.htm file by now. If you haven’t, you can read more about it on ScottGu’s blog post. This technique has been one of my favorite tricks for many years. From time to time, like all of us, I need to take down a high profile site to apply some “enhancements” and I unfortunately can’t wean users off gracefully. I always feel bad when I publish that file to the server, knowing there could be hundreds of users sitting at, in their mind, an inexcusable system maintenance page.
So what are we to do?
I was recently searching for a way to convert LLBLGenPro Entities to JSON when I ran across Josh’s approach. I like the approach but thought there must be an easier way. This approach requires LLBLGenPro 2.6 or above and .NET 3.0.
Here’s an example
Here’s another example with a 1:m return:
Nice thing about using the new linq features in LLBLGenPro is you’re only bringing back the data you care about. Yes, you could always ignore fields, but isn’t it easier to tell it what you want instead of what you don’t want?
Thoughts? I’d love to hear them.