JSP로 여러 파일을 업로드하는 방법은 무엇입니까?JSP로 여러 파일 업로드
양식을 제출할 때 다음 질문이 8 개 있습니다. 각 질문마다 첨부 파일을 보내고 싶습니다. 다음 오류가 나타납니다. 이 내 입력 유형이
"Caused by: java.lang.IllegalArgumentException: Cannot invoke
com.usrinfo.form.AssessmentForm.setAttatchment on bean class
'class com.usrinfo.form.AssessmentForm' - argument type mismatch -
had objects of type "java.util.ArrayList" but expected
signature "org.apace.struts.upload.FormFile"
해결을 도와주세요 :이 메시지에 따라 내 행동
action="xxx.do" method="post" enctype="multipart/form-data">
이 경우 코드 조각을 표시 할 수 있습니까? – mthmulders
action = "xxxxx.do"method = "post"enctype = "multipart/form-data"> 오류를 표시하는 bean 클래스로 보내는 동안 bean 클래스는 다음과 같다 : private FormFile attachment; \t \t 공개 내고 formfile getAttachment() { \t \t 창 부착; \t} \t \t 공개 무효 setAttachment (내고 formfile 첨부) { \t \t this.attachment = 첨부; \t} } 미리 감사드립니다. – user2575422
코드를 올바르게 표시하십시오. –