It's not a secret anymore!*
The moose likes Other Open Source Projects and the fly likes Dynamically configure property in display:column Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "Dynamically configure property in display:column" Watch "Dynamically configure property in display:column" New topic
Author

Dynamically configure property in display:column

Andy Storm
Greenhorn

Joined: Sep 26, 2013
Posts: 8
Hi Everyone,

I'm really stuck here.
I need to do something like this:



but this property cannot be configured like this. Does anyone have an idea how It could be done?

Thanks in advance.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61654
    
  67

Those aren't standard JSP tags. I assume you are using a framework. If so, which one?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Andy Storm
Greenhorn

Joined: Sep 26, 2013
Posts: 8
Hi Bear,
it's fom displaytag.tld

http://java.sun.com/dtd/web-jsptaglibrary_1_2.dtd

<tlib-version>1.1</tlib-version>
<jsp-version>1.2</jsp-version>
<short-name>display</short-name>
<uri>http://displaytag.sf.net</uri>
<display-name>Display *: Tag Library</display-name>

The display tag library is an open source suite of custom tags that provide high level web presentation patterns
which will work in a MVC model, and provide a significant amount of functionality while still being simple and
straight-forward to use. The primary tag in the library is the Table tag.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61654
    
  67

OK, I have moved this to a more appropriate forum.

For future posts it'd be best to mention what you are using.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18907
    
    8

It would also help to explain what you're trying to do, or why you think the code you posted has a problem. My wild guess is that



doesn't translate into



like you expected it to, or something like that. If that's the problem, then I suggest you switch to using EL rather than scriptlets to implement it. Probably a plain old <c:forEach> element would be a straightforward fix, depending on where your "columns" variable is coming from.
Andy Storm
Greenhorn

Joined: Sep 26, 2013
Posts: 8
Hi Paul,

Thanks a lot for your attention and answer. Unfortunately I'm forced to use scriptlets not EL, old project, technological restrictions...

And your undesrtanding is correct, I need to generate <display:column tag and make it working. Seems it's not so easy, I tried even move whole <display:column
generation out of jsp to other class, created complete list and pasted it in jsp but no luck
like this



Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18907
    
    8

Well, you're using a taglib so I don't see any technical reason why you can't use EL. If there's a political reason then I'd suggest you use political means to get that reason changed.
Andy Storm
Greenhorn

Joined: Sep 26, 2013
Posts: 8
Thank you Paul for advice.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Dynamically configure property in display:column