Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Dynamic "id=" attribute for jsp:useBean?

 
Val Pecaoco
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ranchers,
I'm trying to assign a dynamic value to the "id=" attribute of <jsp:useBean>, e.g.,

But I'm getting the ff. error:
org.apache.jasper.compiler.ParseException: C:\Program Files\jakarta-tomcat-3.3a\webapps\dev\foo\bar\foopage.jsp(5,54) Attribute parameterValue has no value
Is it possible to assign a dynamic value to the "id=" attribute? Thanks for the help.
Ex Animo Java!
-- Val
[ April 24, 2002: Message edited by: Val Pecaoco ]
 
Pradeep bhatt
Ranch Hand
Posts: 8927
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It is not possible to assign dynamic value to id attribute of jsp:useBean tag. Use can check the syntax refernce doc at sun site.
 
Val Pecaoco
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Pradeep,
I just belatedly pulled out the syntax card from my file and "id=" is fixed...thanks for pointing that out.
I've already made adjustments to my app
Maybe in future versions of the JSP spec we could have a dynamic "id=" attribute. Please?!
Ex Animo Java!
-- Val
 
Axel Janssen
Ranch Hand
Posts: 2166
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Val Pecaoco:

Maybe in future versions of the JSP spec we could have a dynamic "id=" attribute. Please?!
-- Val

Why should one need that?
I mean the id-attribute is basically a variable name (especially if you look at the servlet code generated by jsp in the work directory).
I don't have dynamic variable names in normal Java programs.
Axel
 
Pradeep bhatt
Ranch Hand
Posts: 8927
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I had felt the need abt that when I coding for one of application 6 months..I dunno why Sun has not provided that facility..
Originally posted by Val Pecaoco:
Hi Pradeep,
I just belatedly pulled out the syntax card from my file and "id=" is fixed...thanks for pointing that out.
I've already made adjustments to my app
Maybe in future versions of the JSP spec we could have a dynamic "id=" attribute. Please?!
Ex Animo Java!
-- Val
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic