RSS

Monthly Archives: June 2012

Get Document Extension in Mysql


you have no need to save extension in database of uploaded document or images.you can get in select statement

 

select tblscandocument.*, (substring(scandocuments,LOCATE(‘.’,scandocuments)+1,length(scandocuments))) as documenttype from tblscandocument

 

 

 
Leave a comment

Posted by on June 13, 2012 in My SQL

 

Tags: ,

How to get style in code from resource +silverlight


Define style in app file

<Application xmlns=”http://schemas.microsoft.com/winfx/2006/xaml/presentation&#8221;
xmlns:x=”http://schemas.microsoft.com/winfx/2006/xaml&#8221;
x:Class=”SetMyLeads.Silverlight.UI.App”
xmlns:telerik=”http://schemas.telerik.com/2008/xaml/presentation&#8221;
xmlns:Telerik_Windows_Controls_MaskedTextBox=”clr-namespace:Telerik.Windows.Controls.MaskedTextBox;assembly=Telerik.Windows.Controls.Input”
xmlns:Telerik_Windows_Controls_Chromes=”clr-namespace:Telerik.Windows.Controls.Chromes;assembly=Telerik.Windows.Controls”
xmlns:sdk=”http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk&#8221;
xmlns:navigation=”clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Navigation”
xmlns:System_Windows_Controls_Primitives=”clr-namespace:System.Windows.Controls.Primitives;assembly=System.Windows.Controls”
xmlns:navPrimitive=”clr-namespace:Telerik.Windows.Controls.Primitives;assembly=Telerik.Windows.Controls.Navigation”
xmlns:System=”clr-namespace:System;assembly=mscorlib”
xmlns:docking=”clr-namespace:Telerik.Windows.Controls.Docking;assembly=Telerik.Windows.Controls.Docking”

xmlns:telerikDocking=”clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking”

xmlns:Telerik_Windows_Controls_Primitives=”clr-namespace:Telerik.Windows.Controls.Primitives;assembly=Telerik.Windows.Controls.Navigation”

xmlns:Telerik_Windows_Controls_TabControl=”clr-namespace:Telerik.Windows.Controls.TabControl;assembly=Telerik.Windows.Controls.Navigation”
xmlns:telerikTest=”clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls”>
<Application.Resources>
<!–TextBox Style –>
<Color x:Key=”BackgroundColor”>#FF3D3D3D</Color>
<Color x:Key=”StandardColor”>#FF808080</Color>
<Color x:Key=”HoverColor”>#FFCCCCCC</Color>
<Color x:Key=”PressedColor”>#FFE5E5E5</Color>
<Style TargetType=”telerik:RadMaskedTextBox” x:Key=”DefaultTextBoxStyle”>

<Setter Property=”MaskType” Value=”None”/>
<Setter Property=”Mask” Value=””/>
<Setter Property=”SelectionOnFocus” Value=”CaretToBeginning”/>
<!–<Setter Property=”MaskedText” Value=”” />–>
<Setter Property=”FontSize” Value=”11″ />
<Setter Property=”FontFamily” Value=”Verdana,Times New Roman”  />
<Setter Property=”Foreground” Value=”Black” />
<Setter Property=”SelectionOnFocus” Value=”CaretToBeginning”></Setter>
<Setter Property=”BorderThickness” Value=”1″/>
<Setter Property=”Height” Value=”22″ />
<Setter Property=”TextAlignment” Value=”Left” />
<Setter Property=”HorizontalContentAlignment” Value=”Stretch”/>
<Setter Property=”VerticalAlignment” Value=”Center”/>

<Setter Property=”IsTabStop” Value=”True”/>
<Setter Property=”IsReadOnly” Value=”False”/>
</Style>

</Application.Resources>
</Application>

LabelSr control name

LabelSr.Style = (Style)(Application.Current.Resources[“DefaultLabelLeftStyle”]);

 
Leave a comment

Posted by on June 11, 2012 in Silverlight