textfield - in java Calculator what should be coding of decimal point button ,i want to check if there is already dot in string so else add a dot in string -


if(!".".contains(jtextfield.gettext())) {     jtextfield.settext(jtextfield.gettext()+ ".");     jtextfield.setbackground(color.magenta); } else {     jtextfield.settext(jtextfield3.gettext());     jtextfield.setbackground(color.green); } 


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -