1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
require "silverlight"

class App < SilverlightApplication
  use_xaml

  def initialize
    message.text = "Welcome to Ruby and Silverlight!"   
    
    js_obj = HtmlPage.window.eval 'object'   
    # js_obj.invoke "test","This is a message".to_clr_string 
    # js_obj.invoke "observe", { puts "Ruby Listener!" }
    
  end
end

$app = App.new