jsp-tags


jstl formatNumber in input leads to NumberFormatException


in my jsp I have this:
<fmt:formatNumber type="number" minFractionDigits="2" value="${myVal}" var="val" />
and I use "val" in an input field. It displays nicely (e.g. 10,000.00).
But when the form is submitted I get a NumberFormatException which didn't happen without the formatting.
I haven't found a way around this - any clues?
Thanks,
John.
When the form is submitted this number (e.g. 10,000.00) goes back to your server(I assume).
In that case the formatted number is now a string with a comma between 10 and 000.00
Make sure what you submit back is a valid number without any characters like comma.

Related Links

JSP foreach tag for two variables
Adding Parameter to href tag before uri
Servlet exception stream closed jsp
creating and exporting a csv from Display tag table
bean write to number type id
restrict image file size in alloy UI
The function getContextPath must be used with a prefix when a default namespace is not specified
how can i retrive parameters from EncodeURL using jsp?
onclick tag giving error in h:commandLink
Displaytag - How to pass hidden value in url?
Embedding Tag Files in a JAR
Errors when the compiler is trying to build a custom JSP tag based on an Java Bean
Creating nested custom tag using jsp2 tag files
Unable to access session on JSP
Dealing with <html:options>
No tag “tableFacade” defined in tag library imported with prefix “jmesa”

Categories

HOME
deezer
push-notification
razor
analysis
rubygems
webpack-2
sql-server-2016
google-project-tango
indesign
bs4
tomcat6
midi
dax
n-gram
windows-phone-7
fallback
zebra-printers
dynamics-crm-online
clearcase-ucm
django-simple-history
telephony
invantive-sql
apache-metamodel
reactcsstransitiongroup
text-rendering
visual-composer
nas
php-openssl
apache-commons-io
facebook-access-token
webkitspeechrecognition
librato
nouislider
google-rich-snippets
create-table
column-family
azure-sql-database
catalog
serverside-rendering
android-browser
jna
fedex
pdf-reactor
core-plot
google-closure
isbn
arena-simulation
bootstrap-dialog
gpx
qcombobox
websphere-mq-fte
galleria
jsch
user-accounts
azure-application-gateway
logparser
pnotify
svmlight
kbuild
typed-lambda-calculus
spring-mongodb
bind9
redundancy
sonarlint-vs
gnome-shell-extensions
specrun
time-and-attendance
ableton-live
nxt
angular-cache
measures
pcf
flash-cs5
pagedlist
master-slave
pagerank
photobucket
jfugue
separator
t4mvc
cyclomatic-complexity
comobject
wordml
tableau-online
method-parameters
createprocessasuser
sonarqube5.1.2
truevault
python-green
oxwall
knuth
angularjs-ng-click
relocation
neolane
jubula
phpthumb
marmalade
mechanize-ruby
jboss-weld
easy-install
flash-builder4.5
type-equivalence
angularjs-controller
e4x
labwindows
krl
disclosure
revisions
gin
forums
substrings
avatar
nerddinner
scripting-languages
paul-graham
ajax-forms

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App