Example #1
0
 protected override ViewModelBase GetDataContext(MessageContent messageContent)
 {
     if (!string.IsNullOrEmpty(HtmlResource))
     {
         HtmlFileViewModel vm = new HtmlFileViewModel(HtmlResource);
         vm.Caption = Caption;
         return(vm);
     }
     else
     {
         throw new ArgumentNullException(
                   "Must assign HtmlResource field in ShowHtmlAction tag.");
     }
 }
Example #2
0
        public HtmlFilePage(BatchFile batchFile)
        {
            InitializeComponent();

            BindingContext = viewModel = new HtmlFileViewModel(batchFile);
        }