10 Minute Tutorial - Silverlight: Using JavaScript to Call Scriptable Managed Code (C#)
My event handling tutorial walked through manipulating a Silverlight control using managed code. Today, we will learn how to access that managed code from JavaScript in an HTML page. The blandness of my last tutorial (a blue rectangle, whoopie) inspired me to spice things up for this tutorial and give you: animated, multi-color rectangles! Lacking the desire or the time to create the necessary XAML myself, I “borrowed” it from one of the samples embedded in the absolutely awesome SilverlightPad application.
Man, I hope that code is open source.
In addition to snazzy animations, the application for this tutorial will also contain a couple of form controls that will manipulate the Silverlight content at runtime. The first control, a simple drop down, will allow the user to select the number of rectangles displayed on the screen. The second form control will act as a pause/resume button for the animation.
Okay, let’s get started! Read more
10 Minute Tutorial - JavaFX: Hello World
Over the past couple of months, I wrote a number of Microsoft Silverlight tutorials both to learn Silverlight and help other developers ramp up their Silverlight skills quickly. Now however, I’ll turn my attention to one of Silverlight’s competitors: JavaFX. If you read the JavaFX section of my introductory post, you already know that Sun has taken a very different approach than Microsoft in implementing a framework for developing easily deployed, highly-interactive, “rich” applications. So, I want to jump right in and create an application that will have everyone hanging on the edge of their seat with enthusiasm (or rolling their eyes and groaning in almost physical pain): Hello World. Read more
10 Minute Tutorial - Silverlight: Event handling using Managed Code (C#)
Managed code.
In the browser.
All my dreams have come true.
Well, not quite. Catherine Zeta-Jones and Lucy Liu still haven’t returned my calls. But, it’s a start!
I wrote this tutorial to illustrate how Silverlight communicates with managed code. So, as a simple example, we’ll use C# to handle click events inside of a rectangle rendered on a Silverlight control. And, like always, you can complete this tutorial sans-IDE, for those users who don’t want to install Visual Studio just to get a taste of Silverlight. Read more
10 Minute Tutorial - Silverlight: Application Framework
In our last Silverlight tutorial, we created the simplest Hello World application possible, using a single HTML file. Starting at the bare minimum allowed us to see exactly what components go into a Silverlight application without using Visual Studio as a crutch or Javascript as a buffer.
So, while the previous tutorial served its academic purpose, it didn’t necessarily create a good foundation for building future Silverlight applications. In this tutorial, we will put a Silverlight application together in the way recommended by Microsoft. Read more
10 Minute Tutorial - Silverlight: Hello World
Today, we will create a VERY basic “Hello World” Silverlight application. Since this is my first tutorial, as an experiment, I will break this tutorial up into three (hopefully self-explanatory) sections including: Prerequisites, QuickStart and Lesson. Over time, I will tweak my tutorial format based on your feedback. But, enough talk…let’s get started! Read more