cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - When posting, your subject should be specific and summarize your question. Here are some additional tips on asking a great question. X

We want to add file from local system to the server as a secondary attachment to wtDocument type

KOEL_PLM
11-Garnet

We want to add file from local system to the server as a secondary attachment to wtDocument type

We have wrote a html code to upload file as follows:

 

 <h3>File Upload</h3>
<form action="UploadServlet" method="post" enctype="multipart/form-data">
         <input type="file" name="file">
         <button type="submit">Upload File</button>
</form>

 

Need code in UploadServlet.jsp to fetch the document and attach it to the secondary attachment of the current wtDocument.

 

Thanks!

 

 

2 REPLIES 2
avillanueva
22-Sapphire II
(To:KOEL_PLM)

Curious what is wrong with the normal check out and edit interface to upload via attachments?

d_graham
17-Peridot
(To:KOEL_PLM)

I’ve written lots of code to get content and to add content.

I take it “name” in your form it the full path to the file? If yes, and you have the document (which I guess is the the document you are running the jsp from) to add the file from a given path as an attachment to the document is no problem.

 

Does that accurately describe the big picture?

If yes, I’d second what Mr Villanueva wrote.

 

If no, how about describing your use case.

Announcements
Top Tags