Article:
 |
|
JSP 2.0: The New Deal, Part 1
|
| Subject: |
|
Dynamically Build Expressions to Evaluate? |
| Date: |
|
2004-03-05 11:54:44 |
| From: |
|
sethladd1
|
|
|
|
Hello,
Thanks for these great articles. Is it possible to evaluate expressions made up of other expressions?
For instance, I have two vars in scope, one bean and one string. The string is the property I want from the bean.
I'd like to do something like this:
${bean.${property}}
Is this possible?
Thanks very much!
Seth
|
Showing messages 1 through 3 of 3.
-
Dynamically Build Expressions to Evaluate?
2004-08-24 10:14:16
amitcbhayani
[View]
-
Dynamically Build Expressions to Evaluate?
2005-06-01 05:22:19
JavaJockey
[View]
-
Dynamically Build Expressions to Evaluate?
2004-04-28 19:26:40
Hans Bergsten |
[View]
I am trying to acchieve what u have said. But I get following error
/pages/event/causalComponents.jsp(52,12) "${componentRows.${columns}" contains invalid expression(s): javax.servlet.jsp.el.ELException: Encountered "{", expected one of ["}", ".", ">", "gt", "<", "lt", "==", "eq", "<=", "le", ">=", "ge", "!=", "ne", "[", "+", "-", "*", "/", "div", "%", "mod", "and", "&&", "or", "||", "?"]' org.apache.jasper.JasperException: /pages/event/causalComponents.jsp(52,12) "${componentRows.${columns}" contains invalid expression(s): javax.servlet.jsp.el.ELException: Encountered "{", expected one of ["}", ".", ">", "gt", "<", "lt", "==", "eq", "<=", "le", ">=", "ge", "!=", "ne", "[", "+", "-", "*", "/", "div", "%", "mod", "and", "&&", "or", "||", "?"] at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:39) at org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407) at org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:200) at org.apache.jasper.compiler.JspUtil.validateExpressions(JspUtil.java:596) at
Any input would be of great help.
Thanks
Amit