Design Time on Windows Store Apps

Topics: UI Architecture
Mar 22, 2013 at 4:42 PM
Hello,

I'm trying to implement design time data on my Windows Store App.

Is this possible?
I haven't seen any example on windows store apps, so I followed one I found about WPF or Silverlight.

I tried something like this:

MyView.xaml
<Page
    x:Class="MyApp.Views.MyView"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:MyApp.Views"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:caliburn="using:Caliburn.Micro"
    xmlns:vm="using:MyApp.ViewModels"
    mc:Ignorable="d"
    d:DataContext="{d:DesignInstance Type=vm:MyViewModel, IsDesignTimeCreatable=True}"  
    caliburn:Bind.AtDesignTime="True"
>
However the MyViewModel doesn't have any constructor with no arguments. So, this code throws an error on d:DataContext line.
Apr 17, 2013 at 6:18 PM