Using Poweshell to kill all the process with name containing particular string

Get-Process| where{ ( $_.Name.ToUpper().Contains(“MAGIC”) ) }| foreach { $_.Kill() }

Advertisements

SAcha Question

Reference Site for C#

http://www.java2s.com/

WPF localization Start

http://robertoschiabel.wordpress.com/2010/01/31/wpf-add-localization-via-resx-files/

The above link is very useful for starters

Debugging Data Binding

http://www.codeproject.com/Articles/244107/Debugging-WPF-data-bindings

(1)  Add a App.Config File

(2) Paste the following code in <Configuration> tags

<system.diagnostics>
    <sources>
        <source name="System.Windows.Data" switchName="mySwitch">
            <listeners>
                <add name="myListener" />
            </listeners>
        </source>
    </sources>

    <switches>
        <add name="mySwitch" value="All" />
    </switches>

    <sharedListeners>
        <add name="myListener" type="System.Diagnostics.TextWriterTraceListener"
             initializeData="DataBindingTrace.txt" />
    </sharedListeners>
</system.diagnostics>

(3) See the magic in bin folder.

Linq TO XML

http://www.dotnetcurry.com/ShowArticle.aspx?ID=564

Changing SlectionColor of ListViewItem

<Window.Resources>
<Style TargetType=”ListViewItem”>
<Style.Resources>
<SolidColorBrush x:Key=”{x:Static SystemColors.HighlightBrushKey}” Color=”Green”/>
<SolidColorBrush x:Key=”{x:Static SystemColors.ControlBrushKey}” Color=”LightBlue”/>
</Style.Resources>
</Style>
</Window.Resources>