Click here to Skip to main content
15,881,757 members
Articles / Desktop Programming / Windows Forms

Clog: Client Logging, WPF Edition

Rate me:
Please Sign up or sign in to vote.
4.51/5 (68 votes)
25 Dec 2008LGPL312 min read 155.4K   964   114  
A customizable log provider system that allows you to harness your existing logging system to log client side messages to your server using WCF. Includes WPF sample applications.
<Canvas xmlns="http://schemas.microsoft.com/client/2007" 
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
        Background="Transparent"
        x:Name="GlassButton"
        >	
	<Canvas.Resources>
		<Storyboard x:Name="MouseOver">
			<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="rectangleColor" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[0].(GradientStop.Color)">
					<SplineColorKeyFrame KeyTime="00:00:00" Value="#FF0455A5"/>
					<SplineColorKeyFrame KeyTime="00:00:00.3000000" Value="#FFACB500"/>
				</ColorAnimationUsingKeyFrames>
		</Storyboard>
		<Storyboard x:Name="MouseOut">
			<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="rectangleColor" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[0].(GradientStop.Color)">
				<SplineColorKeyFrame KeyTime="00:00:00" Value="#FFACB500"/>
				<SplineColorKeyFrame KeyTime="00:00:00.3000000" Value="#FF0455A5"/>
			</ColorAnimationUsingKeyFrames>
		</Storyboard>
	</Canvas.Resources>	
	
	<!--<Canvas Width="20" Height="20"></Canvas>
	<Canvas.RenderTransform>
		<ScaleTransform x:Name="scale" ScaleX="1" ScaleY="1" />
	</Canvas.RenderTransform>-->
	
	<Rectangle Width="100" Height="30" Stroke="#FF767676" RadiusX="10.5" RadiusY="10.5" Cursor="Hand" x:Name="rectangleColor" StrokeThickness="1">
		<Rectangle.Fill>
			<LinearGradientBrush EndPoint="0.5,-1.167" StartPoint="0.5,2.167">
				<GradientStop Color="#FF0B6BC8" Offset="0.418"/>
				<GradientStop Color="#FFFFFFFF" Offset="0.683"/>
				<GradientStop Color="#FF040608" Offset="0.236"/>
			</LinearGradientBrush>
		</Rectangle.Fill>
	</Rectangle>	
	<Rectangle Width="91.5" Height="12" Stroke="#FF000000" RadiusX="5.5" RadiusY="5.5" Cursor="Hand" Canvas.Left="3.75" Canvas.Top="3.5" StrokeThickness="0" x:Name="rectangleShine">
		<Rectangle.Fill>
			<LinearGradientBrush EndPoint="0.5,-3.312" StartPoint="0.5,4.312">
				<GradientStop Color="#2AFFFFFF" Offset="0.572"/>
				<GradientStop Color="#43FFFFFF" Offset="1"/>
			</LinearGradientBrush>
		</Rectangle.Fill>
	</Rectangle>	
	<TextBlock Width="80" Height="20" Canvas.Left="10" Text="TextBlock" TextWrapping="Wrap" Cursor="Hand" Canvas.Top="5" x:Name="Text" FontSize="12" FontFamily="Lucida Sans Unicode"/>	
	<Rectangle Width="100" Height="30" Stroke="#FF000000" RadiusX="10.5" RadiusY="10.5" Cursor="Hand" x:Name="HitShape" Fill="#00000000" StrokeThickness="0"/>	
</Canvas>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The GNU Lesser General Public License (LGPLv3)


Written By
Engineer
Switzerland Switzerland
Daniel is a former senior engineer in Technology and Research at the Office of the CTO at Microsoft, working on next generation systems.

Previously Daniel was a nine-time Microsoft MVP and co-founder of Outcoder, a Swiss software and consulting company.

Daniel is the author of Windows Phone 8 Unleashed and Windows Phone 7.5 Unleashed, both published by SAMS.

Daniel is the developer behind several acclaimed mobile apps including Surfy Browser for Android and Windows Phone. Daniel is the creator of a number of popular open-source projects, most notably Codon.

Would you like Daniel to bring value to your organisation? Please contact

Blog | Twitter


Xamarin Experts
Windows 10 Experts

Comments and Discussions