Dear All,
I have requirement of putting size restriction on 5 MB, I have done this using TBO. But the issue in multiple importing in this case if there are multiple docs for ex: 2MB, 5 MB, 3 MB it will upload only first documents rest will fail and for the second it will show the error
long contentsize = attachmentObject.getContentSize();
if (contentsize > 5242880L)
{
System.out.println("File size greater");
throw new DfException(attachmentObject.getObjectName()+"-- File size is greater than 5MB!!!");
}
How can I import rest of the documents and show user a message that Document 2 and Document 5 Failed.