1 //------------------------------------------------------------
2 // Copyright (c) Microsoft Corporation. All rights reserved.
3 //------------------------------------------------------------
6 namespace System.Activities.Core.Presentation
8 using System.Windows.Media;
9 using System.Windows.Data;
11 using System.Globalization;
12 using System.Activities.Presentation;
13 using System.Activities.Presentation.Model;
15 class ExpressionToExpressionTextConverter : IValueConverter
18 public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
20 string convertedValue = null;
21 ModelItem valueMI = value as ModelItem;
24 convertedValue = ExpressionHelper.GetExpressionString(valueMI.GetCurrentValue() as Activity, valueMI.Parent);
26 return convertedValue;
30 public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
32 throw FxTrace.Exception.AsError(new NotSupportedException());