Hi,
I assume that you are using FormFile class for the upload file control.
Here is the sample to read the data from that form component and convert that into
String.
FormFile uploadFile = frm.getUploadFile();
int size = uploadFile.getFileSize();
char[] theChars = new char[size];
byte[] bytes = uploadFile.getFileData();
for (int i = 0; i < size;)
theChars[i] = (char)(bytes[i++]&0xff);
String fileContent = new String(theChars);
Hope this helps!