Notatki dla .NET w języku programowania C#

MahApps Metro

MahApps

<Controls:MetroWindow x:Class="WpfMetro.MainWindow"
                      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                      xmlns:Controls="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro"
                      Title="MainWindow"
                      Height="600"
                      Width="800" 
                      ShowTitleBar="true"
                      ShowMaxRestoreButton="True"
                      xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
	                  xmlns:Behaviours="clr-namespace:MahApps.Metro.Behaviours;assembly=MahApps.Metro"
                      ShowCloseButton="True">
    <!-- zasoby do ikon -->
    <Window.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="/Resources/Icons.xaml" />
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Window.Resources>
    <!-- menu u gory -->
    <Controls:MetroWindow.RightWindowCommands>
        <Controls:WindowCommands>
            <Button Content="settings" />
            <Button>
                <StackPanel Orientation="Horizontal">
                    <Rectangle Width="20"
                   Height="20"
                   Fill="{Binding RelativeSource={RelativeSource AncestorType=Button}, Path=Foreground}">
                        <Rectangle.OpacityMask>
                            <VisualBrush Stretch="Fill" Visual="{StaticResource appbar_cupcake}" />
                        </Rectangle.OpacityMask>
                    </Rectangle>
                    <TextBlock Margin="4 0 0 0"
                   VerticalAlignment="Center"
                   Text="deploy cupcakes" />
                </StackPanel>
            </Button>
        </Controls:WindowCommands>
    </Controls:MetroWindow.RightWindowCommands>
 
    <Grid>
 
        <Button x:Name="button" Content="Button" HorizontalAlignment="Left" Margin="84,121,0,0" VerticalAlignment="Top" Width="75" Click="button_Click"/>
        <TextBox x:Name="textBox" HorizontalAlignment="Left" Height="23" Margin="84,49,0,0" TextWrapping="Wrap" Text="TextBox" VerticalAlignment="Top" Width="120"/>
 
        <Button HorizontalAlignment="Left" Margin="304,106,0,0" VerticalAlignment="Top">
            <Button.Content>
                <Rectangle Width="20" Height="20">
                    <Rectangle.Fill>
                        <VisualBrush Visual="{StaticResource appbar_close}" Stretch="None" />
                    </Rectangle.Fill>
                </Rectangle>
            </Button.Content>
        </Button>
 
 
        <Button x:Name="button1" Content="Start" HorizontalAlignment="Left" Margin="377,128,0,0" VerticalAlignment="Top" Width="55" Height="55"
        Style="{DynamicResource MetroCircleButtonStyle}">
        </Button>
        <Button Width="55"
        Height="55"
        VerticalAlignment="Top"
        Style="{DynamicResource MetroCircleButtonStyle}" Margin="496,106,240,0">
            <StackPanel Orientation="Vertical">
                <Rectangle Width="20" Height="20" >
                    <Rectangle.Fill>
                        <VisualBrush Stretch="Fill"
                      Visual="{StaticResource appbar_city_chicago}" />
                    </Rectangle.Fill>
                </Rectangle>
                <TextBlock Text="Hello" />
            </StackPanel>
        </Button>
 
    </Grid>
    <i:Interaction.Behaviors>
        <Behaviours:BorderlessWindowBehavior/>
    </i:Interaction.Behaviors>
 
</Controls:MetroWindow>
Kategoria: 

Parameter attributes

[CallerMemberName]
[CallerFilePath]
[CallerLineNumber]
 
 [CallerMemberName] string memberName = "",
 [CallerFilePath] string sourceFilePath = "",
[CallerLineNumber] int sourceLineNumber = 0
Kategoria: 

RabbitMQ

RabbitMQ

url:
localhost:55672

commands:

1. List
rabbitmqctl list_queues.

2. In order to debug this kind of mistake you can use rabbitmqctl to print the messages_unacknowledged field:
rabbitmqctl list_queues name messages_ready messages_unacknowledged

3. list of Exchanges
rabbitmqctl list_exchanges

4. List of Bindings

rabbitmqctl list_bindings.

Glimpse - Debug

Glimpse is a thriving and growing family of open source NuGet packages that provides detailed performance, debugging and diagnostic information for ASP.NET apps. It's trivial to install, lightweight, ultra-fast, and displays key performance metrics at the bottom of every page. It allows you to drill down into your app when you need to find out what's going on at the server. Glimpse provides so much valuable information we recommend you use it throughout your development cycle, including your Azure test environment. While Fiddler and the F-12 development tools provide a client side view, Glimpse provides a detailed view from the server. This tutorial will focus on using the Glimpse ASP.NET MVC and EF packages, but many other packages are available. Where possible I will link to the appropriate Glimpse docs which I help maintain. Glimpse is an open source project, you too can contribute to the source code and the docs.

http://www.asp.net/mvc/overview/performance/profile-and-debug-your-aspnet-mvc-app-with-glimpse

Kategoria: 

Strony

Subskrybuj Notatki dla .NET w języku programowania C#