DCSIMG
Silverlight,Source Code - Alex Golesh's Blog About Silverlight Development

Browse by Tags

All Tags » Silverlight » Source Code (RSS)

Silverlight 4 Tutorial @SDP

My Silverlight 4 Tutorial day at SDP is over. I’d like to thank all participants!!!   As promised, here is source of application I’ve build during the session. Additional samples here and here . Labs could be found here .   See you at Silverlight 4 session tomorrow :) Alex

Silverlight Quick Tip: Dynamically Updating Class Fields/Properties

In previous post ( here ) I blogged about displaying values of class/control in runtime and displaying them in Visual Studio - like property window. Today I’ll show how to push them back to the class instance. In previous post I’ve stored values in “ObservableCollection<FieldsPropertiesData>” for easy databinding and connected this ListBox control. In order to get user input I’ve created TwoWay databinding in DataTemplate – here is updated data template: < Style TargetType ="local:FiledPropertyData">...

Silverlight Quick Tip: Dynamically Displaying Class Fields/Properties

In one of my projects I had to create something like Visual Studio property window, for data set of different controls/data classes. Those controls/classes are still under development and I needed the way to display/change values of those properties dynamically without even knowing what is inside. For the simple case, let’s assume the following class which holds the data: public class SampleData { public SampleData() { BooleanProperty = false ; } public string StringProperty { get ; set ; } public...

Silverlight 3: Hebrew and Arabic Support

Since I’m constantly getting many questions about Hebrew and Arabic support and also huge amount of requests to provide/support it, I’ve updated the SilverlightRTL project at codeplex to support Silverlight 3. The project homepage here . Latest release for Silverlight 3 RTW is here .   The updated source also includes sample application to demonstrate Bidi controls usage and comparison with standard core controls with Hebrew and Arabic:     Enjoy, Alex

Silverlight 3 Quick Tip #6: Navigation Framework and Uri Routing

Silverlight 3 introduced the Navigation Framework and URI Routing features. Today I’ll show how to use those features. To use navigation features you could either create a new “Silverlight Navigation Application” or simply add relevant references to standard “Silverlight application” In case of standard “Silverlight Application” you need to add reference to “System.Windows.Controls.Navigation” assembly and relevant XAML introduce namespace: xmlns : navigation ="clr-namespace:System.Windows.Controls;assembly...

Silverlight 3 Quick Tip #3: Creating custom easing for Silverlight animations

This time I’ll show how to use new easing functions for animations. In Silverlight 3 we could apply one of existing easing functions to our animation (storyboard) or create our own. First, let’s apply existing easing function. On my sample page I have a bunch of buttons to control UI, a stack panel with some path that looks like a spring and a ball attached to it. Also I created a storyboard to animate the Width property: < StackPanel x:Name ="LayoutRoot" Background ="LightGray"...

Silverlight 2 Metro Training Event in Mumbai

I’m doing a Silverlight 2 Training for MS Metro program in Mumbai. Thanks for all participants in this event. Hope you enjoyed the course as much as I enjoyed doing it. As promised the selected samples from this event could be found here . Samples updated…   Thanks and Enjoy the samples Alex

Silverlight 2 Developer Day – a minute after

Thank you all, who participated today at Silverlight 2 Developer Day (Microsoft Israel offices). I uploaded printouts of the slides, presented during the session and the demo code so you can download it for a reference. I’m really interesting within your feedback ( leave comments ) in order for me to be able to enhance it for future events.   PowerPoint printouts here:   Demo project sources here .     Thanks and hope to see you again next time! Alex

Silverlight in the Mesh and the “Cloud” – Hosted Service and Blob Storage (Part 2)

Hello. As I promised here I’m starting to describe my experiences in creating Silverlight Mesh Enabled Web Application (MEWA or SMEWA) with Cloud Hosted Services and Cloud Storage. Today I’ll talk about creating the storage and supported hosted services. First of all I needed to be a part of Windows Azure CTP and have at least 1 Storage account (to have persistent and non-persistent storage in Windows Azure) and at least 1 Hosted Services account (environment that provides the hosting and management...

Silverlight in the Mesh and the “Cloud” – Introduction/Teaser (Part 1)

Hello, For quite some time I’m investigating the Azure Services and Live Framework. After gaining some experience, I decided to build simple project - Content Store – to share with you how to build the next generation of applications. My “Cloud Store” project will use Windows Azure Storage Account to persist content at the cloud, will use Windows Azure Hosted Services as business logic provider (submit contents to the store, display the contents and “purchase” it). Also, my project will use Live...

Silverlight Tip: Dynamic animations

Hello, I was asked about creation of animations dynamically for various elements. Today I’ll show how to create such animations for any (almost) Silverlight element. I’ll create some of popular standard PowerPoint animations. I know that it is not the full set of animations available in PowerPoint, also the animations itself are probably not perfect but it is a good starting point to those who want to know how to do it. Generally, to create the animation on-the-fly we need to create a storyboard...

Silverlight Tip: How to Inject and Execute JavaScript Function(s) on-the-fly from Silverlight

Today I’ve been asked by colleague how to inject and execute JavaScript functionality from Silverlight application to the HTML DOM of hosting page. Well, things are pretty easy. First we need to get JavaScript from somewhere. In colleague's case it was an embedded resource, in my sample I’ll use TextBox to accept the script code. Also I’ll accept function name and parameters from UI. From here we have two approaches: to Eval the function code or to create “Script” element dynamically. First approach...

Quick Silverlight Tips: Control Reflection, Control Properties Data Binding, Window Title and Status Bar text (IE only)

Well it was pretty long time since my last post here… I was busy, mostly doing consulting… Now the pressure is eased of alittle, so I hope to write here more.   During this time I heard a couple of questions from clients which were pretty easy to solve but possibly still not obvious. My first tip today will be about “how to produce reflection under text box” and “emulate PropertyBinding” (like it worked at WPF) To produce reflection (in case of TextBox) I built Vertical StackPanel with desired...

Silverlight TreeView and String-To-PathGeometry Converter projects updated to RC0 syntax

I've updated Silverlight TreeView control and with RC0 changes. Both projects has couple community requested changes. For example, TreeView supports DoubleClick and Single click on node and String-To_PathGeometry Converter supports multiple figures in Path string. Latest sources/build could be downloaded from here (TreeView) and here (String-To-PathGeometry Converter). Enjoy, Alex

Quick Silverlight Tip: Define control style dynamically

Lately I've been asked a couple of time by client how to provide certain level of customization for their Silverlight application. In many cases they want to provide their client with ability to change styles/templates in application or part of it. Another common request, is to provide an ability to use external style definitions. Here the quick tip on how it could be achieved. I'll build really simple solution, which uses WebService to provide external style definition as loose XAML file...
More Posts Next page »