on 11-26-2004 10:36 AM
Hi,
I am trying to upload a file and it is not uploading. I ported the application in J2EE WAS SP7. If i port the application in j2ee+abap WAS SP7 ,the application is working fine. Why upload app is not working in j2ee based WAS?.Below is the code.
<i>
//@@begin onActionSubmit(ServerEvent)
String location = "c:
temp
";
//reingeschraubt!!!
// String fileName = "c:
temp
upload
" + wdContext.currentRootElement().getFileName();
String fileName = location + wdContext.currentRootElement().getFileName();
try{
File file = new File(fileName);
FileOutputStream out = new FileOutputStream(file);
IPrivateView1.IRootElement element = wdContext.currentRootElement();
out.write(element.getFile());
out.close();
}catch(Exception e){
throw new WDRuntimeException(e);
}
wdContext.currentRootElement().setFileName("");
wdThis.wdGetAPI().getComponent().getMessageManager().reportSuccess("File " + fileName + " wurde gesichert!");
//@@end
</i>
Thanks in Advance..
Regards
Vasu
Hi
The File Upload component works fine on WAS with ABAP stack. It works on Java stack if there is some component installed(Dont know what the component name is). We have NWDS 2.0.8 and the WAS 6.40 with SP 8. But the code does not work. I also tried debugging the code and it doesnt seem to even enter the Action say onButtonClick.
But the same code works fine on the WAS with ABAP stack.I got this information from people at SAP TechEd. They told me that in order for the code to work on Java Stack some component needs to be there. I will try to get the exact details and let you know.
regards
Ravi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi .. all , for File Upload , i have an other problem . That is , in my company , we have two WAS servers ( 6.40 SP9 ) , one is installed on Window 2003 Exterprise , one is on AIX . With the same WebDynpro application deployed . A strange result happened , it works in the Window OS , but failed on AIX without any Exception captured . Until now i still can't find out where the problem is ... ><
Hello,
is really nobody out there who have any tips or suggestions to the File Upload Problem.
I see that there are a lot of people (me too) waiting for a functional demo of this UI Control like it was introduced in summer(?)
My Problem:
- method won't be called if a file was choosen
- there is some net traffic so data is transfered but there is no data in the binary context attribute after all
I finally found out the reason for the non-working FileUpload UI element:
The multipart-form is never parsed. To do so, you have to
start Visual Admin, then
go to "Cluster" tab/Server .../Services/Web Container,
then tab Properties,
then change MultipartBodyParameterName from "empty string" to "com.sap.servlet.multipart.body"
That has cost me a h.ll of a lot of time.
I hope it helps others to avoid that...
Holger.
Does anybody have any experinece with File Uploads in Web Dynpro and NetWeaver CE 7.1??
I am facing the following problem:
java.lang.IllegalArgumentException:
at com.sap.tc.webdynpro.clientserver.data.DataContainer.createLocalPath(DataContainer.java:918)
at com.sap.tc.webdynpro.clientserver.data.DataContainer.updateAttribute(DataContainer.java:347)
at com.sap.tc.webdynpro.clientserver.uielements.adaptbase.AbstractAdapter.updateAttribute(AbstractAdapter.java:1324)
at com.sap.tc.webdynpro.clientserver.uielements.adaptbase.AbstractAdapter.updateAttributeAsKey(AbstractAdapter.java:1010)
at com.sap.tc.webdynpro.clientserver.uielib.standard.uradapter.FileUploadAdapter.onFILEUPLOADCHANGE(FileUploadAdapter.java:494)
The only thing I did is binding the resource property of the UI elemnt to a context element of type resource and yet, I keep receiving this exception...
Anybody?? I need help here! Thanks, Johannes
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi Holger,
you have mentioned all the steps for file uploading from web dynpro to KM.could u tell me something about how to upload file from web dynpro to SAP r/3.its very urgent.
thanx in advance.
thanx and regards,
pp
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
File upload works both on the standalone J2EE and on the ABAP+J2EE installation
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.