public static BindingItemExpression Create(string expression, System.Reflection.PropertyInfo destination)
        {
            BindingItemExpression binding = new BindingItemExpression();

            binding._property = destination;
            binding._expr     = expression;
            try
            {
                binding._path = binding.BuildExpressionPath(expression);
            }
            catch (Exception ex)
            {
                throw new ArgumentException("Cound not convert the expression '" + expression + "' to a valid route", "expression", ex);
            }

            return(binding);
        }
Esempio n. 2
0
        public PDFDataBindEventHandler GetDataBindingExpression(string expressionvalue, Type classType, System.Reflection.PropertyInfo forProperty)
        {
            BindingItemExpression expr = BindingItemExpression.Create(expressionvalue, forProperty);

            return(new PDFDataBindEventHandler(expr.BindComponent));
        }