-
Book Overview & Buying
-
Table Of Contents
Mastering LOB Development for Silverlight 5: A Case Study in Action
By :
Most of the time, when data is shown to the user, there are aspects or values, which are not clear or intuitive enough for them. A way to solve this problem is by changing the format or making a conversion before binding. To do so, Silverlight offers an interface which allows us to perform this action.
If you need to make simple formatting (for example, displaying a Date or Time), StringFormat can be directly used on the XAML (this was introduced in Silverlight 4). For more information, please visit http://bit.ly/jMBtDp.
When this interface is implemented, we obtain the following functions:
We will generate an instance to convert the numerical value provided by a property, to an image. The final result will appear similar to the following screenshot...
Change the font size
Change margin width
Change background colour