In this post, we will try to understand the need to download a PDF file from the backend in a single click in VBCS. Let us go through the Problem first and then we will cover the Solution and Conneqtion Approach.
Saving a PDF file as base64 in the backend will be a random combination of numbers and letters. Now, what if the user wants to download the same PDF file from the backend on a click of a button in VBCS.
Step 1: Open VBCS Application in Development Mode.
Step 2: Configure the REST API which returns the base64 as response in the connection.
The code above is pretty self-explanatory but we will try to simplify it for you with a tiny explanation.
Step 4: Create a new button event – ojAction and configure the action items as shown in the screenshot below
Step 5: Assign Input parameter to the repairBase64 function.
Step 6: Assign input parameter to the downloadByteFile function
1) Data will be output of repairBase64 functional.
2) name will be file name.
Roshan comes with an extensive experience in the Oracle Implementation domain after completing his Electronics and Communication Engineering from Bengaluru. He holds a plethora of professional certifications from Oracle after starting as an Associate Developer role and quickly made his way to a Senior Manager. He has worked with clients across the globe in ANZ, EMEA, APAC and Europe. At Conneqtion Group, Roshan has been a key part of managing the organization’s largest risk teams apart from sharing his experience and skills to develop and nurture young talent with his dynamic vision.
I am using the same approach for calling the BIP report from vbcs application but every time error is comming like the string need to be decoded is not in correct encode format. Can you please guide me or share some sample document or application which you have developed.
What is the report format which you’re calling from OIC? Is it in pdf or any other format?
If the report format is not pdf then this method is not suitable.