Standing on the shoulders of giants. RSS 2.0
# Tuesday, October 21, 2008

Scott Hanselman has some great tips for cleaning up disk space under Windows Vista. The best tip is using vsp1cln.exe to remove the sp1 install files.

vsp1cln.exe - After you install Vista SP1, it leaves around the original files so you can uninstall the Service Pack if you want. After a few months with the Service Pack, I've decided for myself that it's a good thing and decided I don't need the option.
Open up an administrative command prompt. That means, click the Start Menu, type cmd.exe, then right-click on it and click "Run as Administrator." Alternatively, you can press Ctrl-Shift-Enter to run something as Administrator.
Next, type "vsp1cln" at the command prompt. If you select yes, you'll get back around 2 to 3 gigs. The only thing, again is that you can't uninstall SP1.

Tuesday, October 21, 2008 12:59:52 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] - Trackback
General
# Monday, October 20, 2008

Last week the timeline for PDC08 was posted on the PDC site. All the sessions you previously selected, to help make a better schedule, are already added to your personal schedule. This is my schedule, based on the sessions I selected. As you can see, I have a small challenge, with 2-4 sessions at the same time, so I’m going to have some difficult choices to make.

Monday, October 27  
8:30 AM - 11:00 AM Keynote
11:00 AM - 12:15 PM Identity Roadmap for Software + Services
Deep Dive: The New Rendering Engine in Microsoft Internet Explorer 8
Under the Hood: Advances in the .NET Type System
12:45 PM - 1:30 PM Datacenters and Resilient Services
"Dublin" and .NET Services: Extending On-Premises Applications to the Cloud
1:45 PM - 3:00 PM Identity: "Geneva" Server and Framework Overview
The Future of C#
3:30 PM - 4:45 PM Microsoft Silverlight, WPF and the Microsoft .NET Framework: Sharing Skills and Code
Deep Dive: Dynamic Languages in Microsoft .NET 
Parallel Programming for C++ Developers in the Next Version of Microsoft Visual Studio
5:15 PM - 6:30 PM Developing and Deploying Your First Cloud Service
Microsoft Visual C++: 10 Is the New 6
WF 4.0: A First Look
IronRuby: The Right Language for the Right Job
Microsoft Visual Studio Team System Database Edition: Overview
Tuesday, October 28  
8:30 AM - 12:00 PM Keynote
12:45 PM - 1:30 PM WCF: Zen of Performance and Scale
1:45 PM - 3:00 PM SQL Server 2008: Developing Large Scale Web Applications and Services
SQL Server 2008: Beyond Relational
Essential Cloud Storage Services
Developing Applications Using Data Services
A Lap around "Oslo"
3:30 PM - 4:45 PM Architecture of the Building Block Services
Identity: "Geneva" Deep Dive
"Oslo": The Language
5:15 PM - 6:30 PM Live Services: Building Applications with the Live Framework
Identity: Live Identity Services Drilldown
Architecting Services for the Cloud
ASP.NET and JQuery
Entity Framework Futures
Wednesday, October 29  
8:30 AM - 11:00 AM Keynote
10:30 AM - 11:45 AM SQL Server Data Services: Futures
Live Services: Live Framework Programming Model Architecture and Insights
Service Bus Services: Connectivity, Messaging, Events, and Discovery
Microsoft Internet Information Services 7.0 and Beyond
WCF 4.0: Building WCF Services with WF in Microsoft .NET 4.0
Parallel Programming for Managed Developers with the Next Version of Microsoft Visual Studio
Panel: The Future of Programming Languages  403AB
12:00 PM - 12:45 PM SQL Server 2008: Developing Secure Applications
Microsoft XNA Game Studio: An Overview
1:15 PM - 2:30 PM SQL Server 2008: New and Future T-SQL Programmability
Logging, Diagnosing, and Troubleshooting Applications Running Live in the Cloud
Modeling Data for Efficient Access at Scale
Concurrency Runtime Deep Dive: How to Harvest Multicore Computing Resources
3:00 PM - 4:15 PM Live Services: Mesh Services Architecture and Concepts
"Dublin": Hosting and Managing Workflows and Services in Windows Application Server
SQL Server 2008: Deep Dive into Spatial Data
Offline-Enabled Data Services and Desktop Applications
"Oslo": Repository and Models
4:45 PM - 6:00 PM .NET Services: Access Control Service Drilldown
Deploying Web Applications with Microsoft Internet Information Services 7.0 and the Web Deployment Tool
Business Considerations for Cloud Computing
WF 4.0: Extending with Custom Activities
Thursday, October 30  
8:30 AM - 9:45 AM SQL Server Data Services : Under the Hood
Dynamics Online: Building Business Applications with Commerce and Payment APIs 
Developing RESTful Services
Microsoft .NET Framework: Declarative Programming Using XAML
Research: Contract Checking and Automated Test Generation with Pex
10:15 AM - 11:30 AM Messaging Services: Protocols, Protection, and How We Scale
ASP.NET: Cache Extensibility
Microsoft .NET Framework: CLR Futures 
1:45 PM - 3:00 PM Workflow Services: Orchestrating Services and Business Processes Using Cloud-Based Workflow
Identity: Windows CardSpace "Geneva" Under the Hood
An Introduction to Microsoft F#
Monday, October 20, 2008 3:03:55 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] - Trackback
Conference | PDC2008
# Monday, October 06, 2008

Blog Bling BrainLast week the final (25) sessions were added to the PDC Session list, making it a total of 178 sessions. I’m not sure which sessions are new or updated, so this list will not be unfamiliar to regular readers of this blog (all 5 of you).

The sessions I will try to attend, if they can schedule around my wishes, are: sessions about “Oslo”, “Zermatt”,  CLR Futures, some language sessions (C#, F#, Dynamic Languages, XAML), “Dublin” and the Parallel Symposium.

Update: I had another look at the session list today and 10 more sessions were added, making it a total of 188.

Monday, October 06, 2008 7:38:07 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [1] - Trackback
Conference | PDC2008

Yesterday dasBlog 2.2 (2.2.8279.16125) was released on CodePlex. This release adds OpenID for comments (and admin login), support for IIS 7 and support for custom 404 pages.

As always you can download the web- and the full install from CodePlex or get the source from repository.

Monday, October 06, 2008 1:38:21 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] - Trackback
dasBlog
# Friday, October 03, 2008

AnnotatedTuringCover25In 1936 Alan Turing wrote a paper "On Computable Numbers, with an Application to the Entscheidungsproblem [0]". The most interesting result of this paper is not the conclusion, that there cannot be a general solution to the Entscheidungsproblem, but how Alan Turing reached that conclusion. In his paper he introduces a computing machine (a Turing machine) with a limited number of operations, by showing that such a machine can not determine the ultimate fate of all other machines, he proves there is not general solution.

In 2008 Charles Petzold wrote "The Annotated Turing", in this book he dissects the original paper from Alan Turing. This book not only presents the original paper (and the appendix and corrections) with numerous annotations and samples, but also is a biography of Alan Turing's life and an introduction to the mathematical background, required for understanding the paper. The book concludes with an overview how the Turing machines can be used to help understand the human mind and the universe.

This is a highly recommended book, which is very accessible for anyone with a general interest in computes and mathematics. And a must read for all developers, who want to understand why there can't be a general program which verifies all programs are error free.

[0] The Entscheidungsproblem asks for a general decision procedure with a finite number of steps to determine the provability of any given well-formed formula.

Friday, October 03, 2008 7:53:13 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] - Trackback
Reading
# Wednesday, October 01, 2008

The ‘normal’ use case for using templated databound controls like the listview control is to specify the control and the templates in declarative markup and bind the control in the code-behind.

 <asp:ListView runat="server" ID="listview">
     <LayoutTemplate>
        <ol><li runat="server" id="itemPlaceholder" />ol>
     LayoutTemplate>
     <ItemTemplate>
        <li><%#Eval("item") %>li>
     ItemTemplate>
 asp:ListView>

and in the code-behind:

listview.DataSource = ....
listView.DataBind();

But when you’re building a webpart or a composite control, this is generally not really an option. The way to define templates in the code-behind is to define two classes which implement the ITemplate interface and assign an instance of these classes to the LayoutTemplate and the ItemTemplate properties. (There are a lot more templates you can use, but these are used to show how the concept works.)

The Layout template is the simplest to define:

private class LayoutTemplate : ITemplate
{
    public void InstantiateIn(Control container)
    {
        var ol = new HtmlGenericControl("ol");
        var li = new HtmlGenericControl("li") { ID = "itemPlaceholder" };
        ol.Controls.Add(li);

        container.Controls.Add(ol);
    }
}

The only requirement is that it control with the ID itemPlaceHolder, the listview uses this ID to find the control to replace with the item template when databinding.

The InstantiateIn method in the item template is similar to that method in the layout template: a control is created (the same type as previously) and this is added to the container control, effectively replacing the child-control (with the itemPlaceHolder ID) from the layout template. The only difference is that we register for the databinding event of the childcontrol. In the databinding method a reference to the childcontrol is obtained (the sender parameter) and a reference to the current item from the bound collection.

private class ItemTemplate : ITemplate
{
    public void InstantiateIn(Control container)
    {
        var li = new HtmlGenericControl("li");

        li.DataBinding += DataBinding;
        container.Controls.Add(li);
    }

    public void DataBinding(object sender, EventArgs e)
    {
        var container = (HtmlGenericControl)sender;
        var dataItem = ((ListViewDataItem)container.NamingContainer).DataItem;

        container.Controls.Add( new Literal(){Text = dataItem.ToString() });
    }
}

Complete source: FibonacciControl.txt (1.88 KB)

Wednesday, October 01, 2008 3:47:00 PM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] - Trackback
ASP.NET
# Monday, September 29, 2008

As Dare Obasanjo writes, there are a number of things you have to give thought when implementing OpenID on your website.

The real question you’ll have to answer is: how easy do I make it for users to participate on my website and how hard do I make it for spammers to flood my website.

But by delegating authentication to an OpenID provider, your implicitly trusting that provider to do the right thing when authenticating a user. Since, as Tim Bray speculated, there is nothing stopping a provider from “succesfully authenticating” any user URL, you can’t blindly trust any OpenID provider. So depending on the requirements you have for the authentication of your users, you can white-list providers you trust (like HealthVault), or if you’re only worried about bots, you can ask them to solve a Captcha. So the consequence is: since you can’t really trust all OpenID providers, so you force your user to register for a specific one (making their OpenID no longer their single online id) or make them to jump through hoops (by proving they are human).

Does OpenID really make it easier for a user to use your site? Or does it make it easier for you (the developer), since you can drop in a control and think you don’t have worry about authentication.

See also: OpenID is too hard & The problem(s) with OpenID

 

 

Monday, September 29, 2008 7:14:58 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] - Trackback
Development | Security

Sample Diagram

Generate your own on the websequencediagrams site.

Monday, September 29, 2008 6:16:18 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] - Trackback
Development
# Tuesday, September 16, 2008

A nice method I discovered today:

System.Globalization.TextInfo.ToTitleCase(string)

This capitalizes the first letter of each word in the string, e.g. "hello world" becomes "Hello World".

Tuesday, September 16, 2008 7:30:19 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [1] - Trackback
Codesnippet
# Monday, September 15, 2008
public class Foo : IComparable<Foo>
{
    public Foo() { }

    public int Value { get; set; }

    public int CompareTo(Foo other)
    {
        if (other == null) { return 1; }

        return this.Value.CompareTo(other.Value);
    }
}

The trick is the line, which checks for the null comparison. Since null is always less than this, the method must return a value greater than zero (0).

Also see the remarks in the documentation:

Greater than zero: This object is greater than other.
...
By definition, any object compares greater than null (Nothing in Visual Basic), and two null references compare equal to each other.

Monday, September 15, 2008 8:55:47 AM (Pacific Daylight Time, UTC-07:00)  #    Comments [0] - Trackback
Codesnippet
Ads
About
© Copyright 2012
Paul van Brenk
Sign In
newtelligence dasBlog 2.3.2011.0
All Content © 2012, Paul van Brenk
DasBlog theme 'Business' created by Christoph De Baene (delarou)