Welcome to Portal

?Unknown\pull-down

Welcome to Zoho Cares

Bienvenido a Soporte de Zoho

Search our knowledge base, ask the community or submit a request.

I have a form where the customer has to upload a file (normally PDF - never jpeg) 
When in report view I want to be able to preview the uploaded file without having to download it. 

If I click on the upload it downloads to my computer, I want to be able to preview it before it downloads. 

Is this possible?

3 users have this question.
14 Replies
Reply
  • Zoho MVP
  • 5 years ago

Hi Tess,
Unfortunately there is no inbuilt preview available within Zoho Creator for uploaded files.

There is a workaround using a page to display the document, you would need to publish the report as this workaround uses google document viewer. In your report you would have a button to pass the ID of the current record along with the file name of the PDF document. In the page you would use these parameters to display the PDF. It's a little temperamental, sometimes doesn't display on first viewing but works once page is refreshed.

The code in the page looks something like:
  1. <%{
  2.     useUrl = "https://creatorexport.zoho.com/file/" + zoho.appuri + "/<Report_Link_Name>/" + input.recordID +"/File_upload/download/<Publish_Key>?filepath=/" + input.fileName;
  3.     %>   
  4.     <iframe src="https://docs.google.com/viewer?url=<%=useUrl%>&embedded=true" style="width: 100%; height: 1000px;"></iframe>
  5.     <a href="<%=useUrl%>" target="_blank">Download Here</a>
  6. <%}%>
Hope it helps,
Damien
bcCloudTech

Would I use a button in the report to direct to the page?

  • Zoho MVP
  • 5 years ago

Hi Tess,

You can use an action in the report, so it could be a button or in the edit menu or even when the record is selected, it's up to you. See: https://www.zoho.com/creator/newhelp/reports/list/create-action-item.html

Damien,
bcCloudTech

  • Creator Certified Developer - Professional
  • 5 years ago

It would be much helpful to have a PDF file preview function, similar as print preview of PDF file . Thanks

I agree. This is a big limitation. Right now I am converting PDF's to JPG's but that is a manual process. Is this on the roadmap? Reason why this is not part of the platform?

  • 5 years ago

Hello,

In regards to the above posts, we would like to let you know that we have taken up viewing the preview of the uploaded file in the report as feature request and forwarded it to our product experts in order to check on the possibilities of implementing the feature.

Regards,

  • Creator Certified Developer - Professional
  • 4 years ago

Please follow the steps below to show the preview of the file uploaded


1)Create a new Dummy form (Dummy_Form) with two fields. This form is a dummy form for us to view a pdf with google docs, the online viewers.

 - File Upload

 - Decision Box

 

2) Now a default report for Dummy form will be created. Go the report( Dummy_Form_Report) and Publish it. This is to enable/allow access for google docs to the files that we need to preview. Please take a note of the Private key form the publish url. for example (private key xxxxxxxxxxxxxxxxxxxxxxx)

 

3) We have to create the url for the preview to load. go to edit of the application> workflow > functions> create a function>

Code:

void Viewer_for_all_reports(int recid, string file)

{

    a = insert into Dummy_Form

    [

    Added_User = zoho.loginuser

    File_upload = input.file

    Decision_box=true

    ];

     openUrl(" http://docs.google.com/viewer?url=https://creatorexport.zoho.com/<app_owner>/<app_name>/Dummy_Form_Report/" + a + "/File_upload/download/" + input.file + "/<private key> ", "Popup window");

 

}

 

4) Configuring the custom action to see the preview of the image

 go to Required report > Report settings > Custom action > select function :Viewer_for_all_reports

field ID- recid

field File_Upload field - file

-
Thanks,
Vignesh

Hi Vignesh,

This function doesn't work because I can't even choose my File_upload field as a function parameter...
Please help!

Hi,

I want to find a similar workaround for Zoho CRM.

Is there a way to automatically upload a file to a web service and populate the file's URL to Zoho CRM?

The workflow would look like this:

1- User insert document in ZOHO CRM upload file field
2- Workflow -- Custom function trigger:
2.1- Fetch file
2.2 Upload to webservice by API
2.3 Fetch url/construct it, maybe using "https://docs.google.com/viewer?url="
2.4 Populate a URL zoho CRM field
3- Send template with URL field

How could I fetch a the file, upload to a webservice and construct the URL using Zoho CRM deluge? I know I could send the file to Zoho Creator, then do the above workaround, but what if I didn't want to use Zoho Creator?

Any ideas will be appreciated.

Thank you!

@Courtierhypo2's.

I have responded to your post in the below forum link.

Thanks.

Any updates on the feature request to preview PDF?

  • Creator Certified Developer - Professional
  • 4 years ago

Hi Christopher,

Currently Preview PDF option was enabled by the Zoho team. Refer the link below for more detail.

Any updates on the feature request to preview PDF?

  • Zoho MVP
  • 9 days ago

Where are you looking to do this? In Creator it's now possible to preview files, see: https://help.zoho.com/portal/en/kb/creator/developer-guide/reports/list-report/articles/understand-preview-of-file-in-list-report

Reply to Tess WilsonA
/* */
  • 12
  • Insert
  • Plain text
Add Comment
(Up to 20 MB )