Foros de discusión

Regarding image upload to document library from a location in LR server

Arun R S Chandran, modificado hace 9 años.

Regarding image upload to document library from a location in LR server

Regular Member Mensajes: 149 Fecha de incorporación: 12/03/13 Mensajes recientes
Dear friends,
I'm trying to do a image upload to document_library using the DLFolderLocalServiceUtil. I've a docx fie which contains some images. I'm extracting that images into bin/media directory(by the way it is done by the api ... emoticon )

I'm trying to get the file from the bin directory and trying to upload it into the document_library. The upload was successful, and I was able to get the url for that image as well.

But the problem is when I access the image using the URL, it's showing me a corrupted image. It is not showing the image exactly. How can I solve this issue?

In the same time, when I directly upload an image using a form and executed the same code block to move it into the document library, it was successful and when I access the Image URL, it was showing the right image.

1. Can I move file directly to document library from the file system?(I was able to do this but was getting corrupted when I access the document library url)
2. Is there any way to move files into document library other than upload request?

Help is appreciated. I'm really in need of understanding this area.

Thanks in advance.

Arun R S
Arun R S Chandran, modificado hace 9 años.

RE: Regarding image upload to document library from a location in LR server (Respuesta)

Regular Member Mensajes: 149 Fecha de incorporación: 12/03/13 Mensajes recientes
I found the issue. It was a coding mistake done by me. I was passing wrong parameters into the addFileEntry method.