Tuesday, 15 February 2011

jsp - Make chart title as capitalize -



jsp - Make chart title as capitalize -

how create title first letter capital , rest of them in lower case , create font italc

string snametitle=request.getparameter("name"); snametitle=name.replace("_"," "); jfreechart chart = chartfactory.createxylinechart("reflectance graph "+snametitle,"wavelength(nm)","reflectance(%)",xydataset,plotorientation.vertical, false, false,false);

any 1 sugesst me create titleof jfree chart hyptis suavalovens

you can utilize javascript function this:

string.prototype.capitalize = function() { homecoming this.replace(/(?:^|\s)\s/g, function(a) { homecoming a.touppercase(); }); };

usage:

var name = 'andi sholihin'; var name_caps = name.capitalize(); alert(name_caps);

output :

andi sholihin

more info : capitalize words in string

jsp jfreechart

No comments:

Post a Comment