Skip to main content

Posts

Showing posts from March, 2013

Currency Format with comma's in SQL Server-2008

Sometimes you want to have your money fields properly formatted with commas like this: 10,000,000.34 DECLARE @amount AS DECIMAL SET @amount = 11000000 SELECT CONVERT ( VARCHAR , CAST ( @amount AS MONEY ),- 1 ) AS 'Amount' Output  

What Is XAML?

XAML or Extensible Application Markup Language (pronounced " zammel ") is a XML based language used to create rich GUI’s. XAML specifies the user interface for Silverlight or WPF application. XAML is used declare controls on Silverlight or WPF Page.  In simple terms XAML Page is similar to .Aspx Page in asp.net website.  In .Aspx Page we use Html to form UI, while in XAML we use Xml to form UI It supports both vector and bitmap images  XAML is a new markup language which is used for defining UI elements and its relationships with other UI elements.  XAML is a XML document which defines objects and properties and WPF loads this document in actual memory.  Using XAML, you can create any kind of objects that means graphical or non-graphical.  XAML is a declarative XML-based language by which you can define object and properties in XML  XAML document is loaded by a XAML parser. XAML parser instantiates objects and set their properties. XAML describes objects, pr

Attached Properties in WPF

An attached property is a property that is declared by one control and attached to another. It allows the inclusion of additional information with a control for later use by an external source. An attached property is a special form of dependency property that can effectively be attached to arbitrary objects. This may sound strange at first, but this mechanism has several applications in WPF.They are basically used to control layout. Every control has its own set of intrinsic properties. Let's take an example of text box which has a specific font, text color, and text content as dictated by properties such as FontFamily, Foreground, and Text.) Now when you place a control inside a container it gains additional features, depending on the type of container. For example, if you place a text box inside a grid, you need to be able to choose the grid cell where it’s positioned.) These additional details are set using attached properties. Attached properties always use

What is the Triggers in WPF?

Triggers are implemented as part of styles, and indicate a trigger condition and a new set of setters to apply when the trigger condition is met. Mouseover effects are a very common application of triggers. Triggers can fully be expressed using XAML, eliminating the need to write code for many simple effects. There are three types of triggers in WPF: 1. Property Triggers - run when the value of a dependency property changes 2. Data Triggers - run when the value of any .NET property changes, using data binding 3. Event Triggers - run when a routed event occurs Triggers are implement as part of a style using the <Style.Triggers> property element, and a series of <Trigger>,<DataTrigger>, or <EventTrigger> elements. Property Triggers Property triggers are used to monitor a DependencyProperty's value. The following example applies a glow effect to a button when the mouse pointer is over the button (IsMouseOver=true). The WPF framework automatically h

WPF Interview Questions?

What is WPF? WPF stands for Windows Presentation Foundation . It is an application programming Interface for developing rich UI on Windows API and WINfx. WPF is introduced in .NET 3.0. By the use of WPF we can Capabilities to HTML and flash. Has all equivalent common user controls like buttons, check boxes   sliders etc. Fixed and flow format documents  2D and 3D dimensional  graphics  Multimedia  Data binding What Is XAML? XAML ( Extensible Application Markup Language ) is a XML based language used to create rich GUI’s. It supports both vector and bitmap images XAML is a new markup language which is used for defining UI elements and its relationships with other UI elements. XAML is a XML document which defines objects and properties and WPF loads this document in actual memory. Using XAML, you can create any kind of objects that means graphical or non-graphical. XAML is a declarative XML-based language by which you can define object and properties in XML