This content has been marked as final.
Show 3 replies
-
1. Re: UI Labels and displaying the hash sign #
zzzz8 Aug 12, 2006 7:02 PM (in response to zzzz8)Oops, that was a typo:
Cannot get value for expression '#{messages['RequestNumber.Short']}'
should have been:Cannot get value for expression '#{messages['TestNumber']}'
The error still occurs...notwithstanding my bumbling copy and paste. -
2. Re: UI Labels and displaying the hash sign #
raja05 Aug 14, 2006 12:41 AM (in response to zzzz8)I think thats a seam bug. Seam tries to interpolate any expressions in the message bundle values and since it found a "#" in there, it seems to be looking for characters next to it, which wont be there in your case. Here is the snippet from Interpolator.interpolate thats causing the bug
FacesContext context = FacesContext.getCurrentInstance(); StringTokenizer tokens = new StringTokenizer(string, "#{}", true); StringBuilder builder = new StringBuilder(string.length()); while ( tokens.hasMoreTokens() ) { String tok = tokens.nextToken(); if ( "#".equals(tok) ) { String nextTok = tokens.nextToken();
which would fail in your case. Other than filing a bug, the one option you have is to split your message content to have just the "Test" portion and include the "#" directly in your jsp page. -
3. Re: UI Labels and displaying the hash sign #
gavin.king Aug 22, 2006 11:01 PM (in response to zzzz8)I believe I already made this more robust in CVS. Try a current CVS build.