locked
Behaviors in latest Expression Blend 5 preview RRS feed

  • Question

  • Anyone else notice that there are no behaviors in the latest Blend 5 preview?  Is there a workaround for this?  Basically, I need to get a storyboard to start when a childwindow is loaded... tried hand typing the syntax in XAML, using:

    <i:Interaction.Triggers>
    <i:EventTrigger>
    <ei:ControlStoryboardAction Storyboard="{StaticResource Storyboard1}"/>
    </i:EventTrigger>
    </i:Interaction.Triggers>

    But get an error and won't compile.  Ran into problems with images too, but hand typing the image source path solved that...

    Appreciate any help

    Thanks

    Saturday, June 23, 2012 8:41 PM

Answers

  • Just to clarify, there are no Storyboards in HTML Metro apps. XAML Metro apps do support Storyboards.

    Actions (and Behaviors, which derive from Actions) are not currently supported in Metro apps (HTML or XAML). You can manually trigger storyboards (where they're supported) using Storyboard.Begin().

    Sorry it's not the answer you're looking for, but hopefully that clears things up.

    Monday, June 25, 2012 6:50 PM

All replies

  • When you say "the latest Blend 5 preview", do you mean the Expression Blend Preview for Silverlight 5, or do you mean the Blend for Visual Studio 2012 RC? If you mean the former, behaviors should be present for WPF and Silverlight projects (and Windows Phone projects, if you have the phone toolkit installed). If you mean the latter, behaviors are not currently supported for HTML or XAML Metro apps.
    • Edited by Brian Hilstrom Monday, June 25, 2012 1:36 PM added WP7 reference
    Monday, June 25, 2012 12:46 PM
  • In Blend for VS 2012 RC, it is true that Behaviors are not available.  But the question remains as to how one should then run storyboards.  I have run into this as well for a XAML Metro app.  What is the recommended work around for this?


    Michael Halvorson

    Monday, June 25, 2012 6:25 PM
  • Just to clarify, there are no Storyboards in HTML Metro apps. XAML Metro apps do support Storyboards.

    Actions (and Behaviors, which derive from Actions) are not currently supported in Metro apps (HTML or XAML). You can manually trigger storyboards (where they're supported) using Storyboard.Begin().

    Sorry it's not the answer you're looking for, but hopefully that clears things up.

    Monday, June 25, 2012 6:50 PM
  • I understand the HTML Metro apps situation, but for SL5 projects, when using Blend 5 Preview there are no behaviors shown under Assets.  I will go with the C# code behind manual approach you suggest in the meantime, but will appreciate some guidance on why things are missing under assets for SL 5 projects.
    Tuesday, June 26, 2012 6:35 PM
  • You're right -- they should be there for SL5 projects. Do you have the correct assemblies (SL5, not SL4) referenced?
    Tuesday, June 26, 2012 6:39 PM
  • I have the same problem as the original poster of this question:

    I assume by SL5 you mean Silverlight 5? But this is not present in  VS 2012. So how do you change the assemblies referenced because I thought it came with the installation package?

    Many thanks for any help given.

    Brenda

    Thursday, July 12, 2012 1:38 PM
  • Expression blend for Silverlight 5 Preview does not show any custom behaviors written in the project. Is this a bug?


    Creativity Flows

    Monday, July 16, 2012 1:56 PM
  • Expression Blend 5 for Win8 RP at present time does not have the libraries written to support behaviours. It will do so I am told.
    Thursday, July 19, 2012 1:44 PM
  • Reloading the project, got the custom behaviors into blend for Sl5. Also make sure the project is only referencing SL5 DLLs.

    Creativity Flows


    • Edited by NatrajB Friday, July 20, 2012 1:35 PM
    Friday, July 20, 2012 1:34 PM
  • Once again a feature pushed hard by MS to "help" developers gets dumped.

    Why on earth would you leave out Behaviors in VS 2012? This is a major part of SL development and causes a huge amount of work for any organization trying to port to VS 2012.

    This is not just about Storyboards. MS recommended repeatedly to use Behaviors for everything possible, now you just summarily wave it off and exclude the class entirely. Honestly I get sick in my gut when I see crap like this.

    It isn't funny, clear, and it is not insignificant. There is no reason Metro apps based on XAML could not take full advantage of the Behavior class.


    Eric Kleeman Senior Dev Engineer Inovalon

    Monday, January 7, 2013 2:20 AM