caliburn.micro - Is it possible to have Intellisense in XAML when using Caliburn automatic datacontext? -


when use caliburn, view gets datacontext set dynamically @ runtime convention. however, nice if set in designer vs , compiler verify , provide intellisense without interfering caliburn binding.

if set myself, like:

datacontext="myapp.mainviewmodel" 

i don't caliburn binding.

is possible set designer?

i think can take advantage of design-time support provided caliburn.micro.

you have set desinger-datacontext , tell cm enable magic in view xaml:

xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:vm="clr-namespace:caliburndesigntimedata.viewmodels" xmlns:cal="clr-namespace:caliburn.micro;assembly=caliburn.micro" mc:ignorable="d"  d:datacontext="{d:designinstance type=vm:mainpageviewmodel, isdesigntimecreatable=true}" cal:bind.atdesigntime="true" 

for work, viewmodel must have default constructor. if isn't suitable, > can use viewmodellocator design-time viewmodel creation.

all of taken documentation page on design-time support.


Comments

Popular posts from this blog

java - Run a .jar on Heroku -

java - Jtable duplicate Rows -

validation - How to pass paramaters like unix into windows batch file -