Debugging JavaScript in Chromium Embedded Framework
You may also use ShowDevTools() extension method (source) ChromiumWebBrowser browser = new ChromiumWebBrowser(); browser.ShowDevTools(); // Opens Chrome Developer tools window
You may also use ShowDevTools() extension method (source) ChromiumWebBrowser browser = new ChromiumWebBrowser(); browser.ShowDevTools(); // Opens Chrome Developer tools window
You are on the right track. The parent model would naturally contain a list of child models, e.g. a customer having multiple orders. When ParentViewModel is created and loaded by a third-party, it is passed a ParentModel. Then the ParentViewModel will: Assign the ParentModel to a local variable Create a ChildViewModel for each ChildModel by … Read more
Go to the image within VS and set the item to be a Resource. Right click -> Properties -> Build Action -> Resource Update: You need to change the path if it is in a folder. ie…Resources/background.jpg
I just moved a project from Prism to MvvmLight and it seems to work faster (very subjective). Both Prism and MvvmLight have Mediator realisation (IEventAggregator in Prism, IMessenger in MvvmLight). But IMessenger has more abilities (for instance, sending messages with tokens) compared to IEventAggregator and is much more convenient to use (see next item). MvvmLight … Read more
I use simple Markup Extension for that: /// <summary> /// Simple extension for icon, to let you choose icon with specific size. /// Usage sample: /// Image Stretch=”None” Source=”{common:Icon /Controls;component/icons/custom.ico, 16}” /// Or: /// Image Source=”{common:Icon Source={Binding IconResource}, Size=16}” /// </summary> public class IconExtension : MarkupExtension { private string _source; public string Source { get … Read more
private void dgrid_RowEditEnding(object sender, DataGridRowEditEndingEventArgs e) { if (this.dgrid.SelectedItem != null) { (sender as DataGrid).RowEditEnding -=dgrid_RowEditEnding; (sender as DataGrid).CommitEdit(); (sender as DataGrid).Items.Refresh(); (sender as DataGrid).RowEditEnding += dgrid_RowEditEnding; } else Return; //then check if the newly added row is duplicated }
The main difference between the Dispatcher and other threading methods is that the Dispatcher is not actually multi-threaded. The Dispatcher governs the controls, which need a single thread to function properly; the BeginInvoke method of the Dispatcher queues events for later execution (depending on priority etc.), but still on the same thread. BackgroundWorker on the … Read more
Value changes fired by INotifyPropertyChanged are automatically marshalled back onto the dispatcher. (http://blog.lab49.com/archives/1166) Fire this event on any thread you like… Value changes fired by INotifyCollectionChanged are NOT reliably marshalled onto the dispatcher. (http://csharplive.wordpress.com/2008/09/11/wpf-data-binding-observablecollection-cross-thread-binding-support/) If you need to update an observable collection from a different thread, follow the advice in this link
Depending on the applications use, I would recommend using SQL Lite because it doesn’t require you to install any other software (SQL CE or Express, etc. usually would require a separate install). A list of the most important benefits for SQL Lite from the provider link at the bottom of this post: SQLite is a … Read more
I was able to achieve something like this in pure xaml using a Brush to paint the main grids background. This way only parent grid will have its opacity set and its child elements won’t inherit it. <Grid x:Name=”LayoutRoot”> <Grid> <Grid.Background> <SolidColorBrush Color=”Black” Opacity=”0.5″/> </Grid.Background> <Grid.RowDefinitions> <RowDefinition Height=”0.333*”/> <RowDefinition Height=”0.333*”/> <RowDefinition Height=”0.333*”/> </Grid.RowDefinitions> <Grid.ColumnDefinitions> <ColumnDefinition … Read more