on 03-05-2008 10:56 AM
Hi Friends,
I am trying Fileupload UI element. I have created a value attribute of type Binary and mapped it to UI.
On click of a submit button, I am checking if the attribute is empty. Below is the code for onAction:
IPrivateAppView.IContextElement element = wdContext.currentContextElement();
if(element.get<attibute>!=null){
IWDAttributeInfo attributeInfo = wdContext.getNodeInfo().getAttribute(<attribute>);
IWDModifiableBinaryType binaryType = (IWDModifiableBinaryType)attributeInfo.getModifiableSimpleType();
String filename = binaryType.getFileName();
wdComponentAPI.getMessageManager().reportSuccess("File Name:" filename);
}
else {
wdComponentAPI.getMessageManager().reportException("no file",true)
}
If I am not selecting any file, I am getting the "no file" message.
But after selecting any file and clicking the button, I am getting the below error.
java.lang.NoSuchMethodError:com.sap.engine.services.servlets_jsp.lib.multipart.MultipartMessage.setCharset(Ljava/lang/String;)V
I can understand from SDN that it is because of the version issues.
My Webas is 6.40 SP 17. Initially I had NWDS 2.0.16. Now I have upgraded to 2.0.17. But still I am facing the issue.
Also in NWDS for default I have j2sdk 1.4.2_09.
The above logic is working fine on server which is on windows. Now I am trying to implement in different server which is on Unix.
I have lots of other projects developed on NDWS 2.0.16 working fine in Unix.
Could you please help me in solving the issue.
Thanks in advance!
Saravanan
Hi,
have you already solved this issue? If not, please take a look at the following SAP notes
1033356 ( Multipart non-ASCII header values support) and
1025462 (640 SP19/700 SPS10,11 http and servlet_jsp).
Maybe they will be of help.
Regards,
Thomas
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Why you have declared value attribute of typr binary.Instead of that you can create a value attribute of type com.sap.ide.webdynpro.uielementdefinitions.Resource and bind it to the Fileupload element.
Regards,
Sudhir
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sudhir,
Thanks for the response. As I mentioned, I am working on NWDS 04. So I dont have the option of having value attribute as "Resource".
One additional Info:
I have 2 tabs in my WD view. In one of the tabs I am having the fileupload UI.
After selecting the file when I navigate to next tab, I am getting the same error message.
Any other options or check required for solving the issue.
Regards,
Saravanan
Edited by: Saravanan on Mar 6, 2008 5:18 PM
One additional info.
I am getting this error only when I try to access the value attribute of type Binary.
Any ideas on solving the error is higly appreciated.
Thanks in advance!
Saravanan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
72 | |
11 | |
10 | |
7 | |
6 | |
6 | |
6 | |
6 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.