locked
Background gradient with Silverlight which can be applied to asp.net c# page RRS feed

  • Question

  • Hi,

    Is it possible to design a gradient background (e.g. light red to dark red) using expression blend which can then be placed into a .xaml file, then copied into a asp.net page for my website. I'm a beginner with Silverlight and any help would be greatly appreciated.

     

    Thanks,

     Jas

    Friday, December 19, 2008 12:41 PM

Answers

  •  Hi Jas,


    The Silverlight xaml can only "live" in the context of a Silverlight application.  Though you put the Silverlight application on an ASP.NET page, it doesn't affect the area "around" the Silverlight application.  It sounds like you're wanting a Silverlight background for ASP.NET content, which I don't think is possible.  Think of the Silverlight app as a sandbox that sits on an ASP.NET page (like an Applet) but is almost totally separate with limited ability to interact with the ASP.NET page.  

    Tuesday, December 23, 2008 10:32 AM

All replies

  • Hi

    This possible you can use a  XAML string and use createFromXaml or XamlReader to instantiate the Silverlight objects.

    Tuesday, December 23, 2008 3:45 AM
  •  Hi Jas,


    The Silverlight xaml can only "live" in the context of a Silverlight application.  Though you put the Silverlight application on an ASP.NET page, it doesn't affect the area "around" the Silverlight application.  It sounds like you're wanting a Silverlight background for ASP.NET content, which I don't think is possible.  Think of the Silverlight app as a sandbox that sits on an ASP.NET page (like an Applet) but is almost totally separate with limited ability to interact with the ASP.NET page.  

    Tuesday, December 23, 2008 10:32 AM
  •  Hi Jas,


    The Silverlight xaml can only "live" in the context of a Silverlight application.  Though you put the Silverlight application on an ASP.NET page, it doesn't affect the area "around" the Silverlight application.  It sounds like you're wanting a Silverlight background for ASP.NET content, which I don't think is possible.  Think of the Silverlight app as a sandbox that sits on an ASP.NET page (like an Applet) but is almost totally separate with limited ability to interact with the ASP.NET page.  

     

    I don't think this is necessarily true.  It might be possible to have a silverlight background (with some cool animations or something) if you were to load your app into a div tag.  Make the div tag take the whole screen and set its z-index to less than the one that your content holds.

    You would have to find a way to make only your content scroll, but I think it could be done.

    Joshua Foulk

    Monday, January 19, 2009 10:01 PM