Skip to main content

Microsoft Silverlight

Advanced Forum Search Results

  • Re: How to create a dependency object in JavaScript?

    You are right Wolf, I'll use that instead. Thanks a lot!
  • Re: Attach a JavaScript Object to a Silverlight element

     Hi Jonathan,  Thanks for getting back to my problem. setJSObject is a method that would like to define but I don't know how to define it. I have continued my work on that and what I did is create a dependency Property that would be a ScriptObject. The idea is I would attach my JS object to my Ellipse. I have two possibilities to ...
  • Convert a ScriptObject back to a UIElement

    Hello, I am creating a new Ellipse which is a UIElement and passing it as a ScriptObject, is there a way to Convert this ScriptObject back into a UIElement? Please take a look at the SetScriptObject in which I want to do my conversion. [Page.xaml.cs] using System; using System.Collections.Generic; using System.Linq; using System.Net; using ...
  • Re: Attach a JavaScript Object to a Silverlight element

     Hi Jonathan, Thanks for having a look at the code, you're right this code works but not if you uncomment the lines 72, 90 and 92 because my goal is to find a way to attach somehow myJSObject to the Silverlight Ellipse element and then be able to get it back in the method shapeClicked that is called when you would click on it. If you ...
  • How to create a dependency object in JavaScript?

    Hello, I have create a CustomUserControl class and I would like to be able to create new custom objects from JavaScript. In my example, I want to create a custom Ellipse by doing: var ellipseDef = '<Ellipse Height="50" Width="50" Fill="Red" Canvas.Left="30" Canvas.Top="100"/>'; var ...
  • Re: Problem using "LayoutUpdated" event in JavaScript

     Thanks a lot for the detailed information. I did try to use the downloader but this is very strange because the image doesn't appear anymore and I go three times in the onDownloadProgressChanged method even though I remove the event listener on the downloader and set it to null. var slPlugin = null; var downloader = ...
  • Attach a JavaScript Object to a Silverlight element

    Hello, I would like to find a way to attach a JavaScript Object to a Silverlight element (an Ellipse in this case). In my example, I have created a myJSObject which I would like to attach to the ellipseXamlNode (see Line 72) so that when I click on it, I am able to access myJSObject (see Line 90).1 <!DOCTYPE html PUBLIC "-//W3C//DTD ...
  • Problem using "LayoutUpdated" event in JavaScript

    Hello, My goal is to determine when my Image is completely rendered. Apparently using the "Loaded" event is not enough as it "is not guaranteed to occur after the template is applied." So I think I should use the "LayoutUpdated" event:  ...
  • Re: Close Line Path Bug

    Hi Amanda, I think you were on the good track. Actually, the default value for the StrokeLineJoin is "Miter" (http://msdn.microsoft.com/en-us/library/system.windows.shapes.shape.strokelinejoin(VS.95).aspx) and for the StrokeStartLineCap/StrokeEndLineCap it is "Flat" ...
  • Close Line Path Bug

     Hello, I was looking for a way to overcome the problem of antialising in Silverlight by shifting my path of 0.5 pixels as described here: http://www.wynapse.com/Silverlight/Tutor/Silverlight_Rectangles_Paths_And_Lines_Comparison.aspx and I could not understand why my two pixels line path would be rendered so big (about 10 pixels wide). Then ...
1 2 3 4 5 Next >
Microsoft Communities