Author Archive

Use Case: How can I merge a checkbox image into my template to show as either checked or unchecked on the generated document?

Full Use Case:
I have checkbox field on my Salesforce record that is either marked True or False. Rather than merging the value of the field as True or False on my generated document, I would like to merge the actual checkbox image showing as checked or unchecked. How can I do that?

Consulting Reply:
You can conditionally merge images based on the checkbox values. You should create two images: 1st with the checkbox checked, 2nd checkbox unchecked, and then have a formula field that display either 1st or 2nd image depending if the actual checkbox is checked in Salesforce or not. You can review this conditional merge section article for more detail on this feature as well as this article for how to create and merge images onto your template.

How do I update method of payment for RS/A5 Documents app subscription?

To Update Method of Payment for A5 Documents:

  1. Login to AppExchange and click your name in the top right, then ‘My Account’ or ‘My Installs & Subscriptions.”
  2. Click on the drop down arrow for RS/A5 Documents subscription and click “manage subscription.”
  3. Click to edit and follow steps to update method of payment.
  4. Click save.


If you need to change number of users for the app subscription or assign any new Salesforce users to the app in Salesforce, please review the activation instructions.

Use Case: I would like to merge the name of the current Salesforce user that is generating the document into template.

Full Use Case:
I would like to merge the first and last name of the Salesforce user that is currently generating the document into the template. How can I build this?

Consulting Reply:
You create a formula field on the object you are merging from. For this example,  lets use Opportunity object.  When you create the formula field call it “User Full Name” and when you build the formula you can insert a field to merge into that formula field.  When you go to advance and insert field you can select to merge from current User.  Starts with $User and would look something like $User.First Name.  After creating the field on the Opportunity you can view it on the page layout and see that it will just display who ever the current user is logged into salesforce at anytime.  And so then merge this new formula field you created into the template.

Use Case: Is it possible to do table grouping with related list items?

Full Use Case:
Is it possible to do table grouping with related list item so that the related list tables are grouped by product category, for example?

You can merge the related list and sort by the product category.  You could also use the filter option if you wanted to merge a related list for each product category. Details on the filter and sorting feature are shown in this related article.

Error Message: “Insufficient Privileges. You do not have the level of access necessary to perform the operation you requested.”

Full Error Message:
“Insufficient Privileges. You do not have the level of access necessary to perform the operation you requested. Please contact the owner of the record or your administrator if access is necessary. For more information, see Insufficient Privileges Errors. ”

  • You may see this error message if a Salesforce user is restricted to any of objects or components being used with the app. For example, does the user have access to document action object and the base object being used in document action to build template? You can check sharing settings by going to Setup > Security Controls > Sharing Settings. Click “edit” if you need to change the settings on any object.
  • Another reason you could see this error message is if you installed the app package for Admin’s only rather than All Users. This type of install would restrict the app package components to any non admin users. You may need to uninstall the app package and then reinstall it from AppExchange for all users. We suggest to submit a case to Salesforce support to make sure this is what you need to do. If you have configurations setup in org that you want to save or want assistance from our Consulting team to do this for you, contact to link you with Consulting  team.
  • Steps to uninstall the package: Setup > Installed Packages > A5 Documents > Click on “uninstall package.” You will have to make sure no custom buttons are on page layout or any other fields in use that in preventing you from uninstall. You will get an error notification after trying to uninstall letting you know the steps needs to successfully uninstall. Then once uninstall is complete, you should go to permanently uninstall it.

Document Action Button/Link Code for Lightning Experience Users

“Save” your Document Action to Generate Custom Code: 

Once you have completed all needed fields in document action, click “Save” to save your Document action. A completed Document Action will auto-generate Action ID and Button/Link Code:

  • Button/Link Code. Code for the Button or Link that will be used for Document generation (copy this value to your clipboard, you will need it in the next step).
    • IMPORTANT NOTE for LEX USERS Using Opportunity Object: If you created the document action in Lightning experience and using Opportunity as your base object, there will be an extra value added to custom code in front of your object ID in document action: http://. So you need to remove this from button code when pasting into custom button. This will only happen if you create the document action in Lightning Experience, this will not happen if you create in Classic and use in Lightning Experience.
    • For example, the final button code at bottom of saved document action will say
      “/apex/rsdoc__GenerateDocument?id={!http://Opportunity.Id}&templateId=GDT-000000&attach=true&output=pdf&emailAction=Preview&emailTo=&emailTemplate=&emailToAdditional=&emailCC=&emailBCC=” though when pasting your code into custom button, you will want to remove this added hyperlink to object (http://) so the final code you would paste correctly is:
    • In addition you can manually setup what Salesforce fields to update upon Document Generation by adding in the end of this code next variables: &fieldtoupdate1=StageName&fieldtoupdatevalue1=Proposal Sent, where:
      • &fieldtoupdate1= API Name of the field that you want to update (Opportunity stage in our Example)
      • &fieldtoupdatevalue1=New value of the field (In our example new value will be “Proposal Sent”)
      • Put  consequential  after variable if you want to update more than one field: &fieldtoupdate1=API_Field1&fiedtoupdatevalue1=Field1_NewVale….&fieldtoupdateN=API_FieldN&fiedtoupdatevalueN=FieldN_NewVale*field to update cannot be used with boolean fields, like checkbox

Error Message: Error: 401. “Request is missing required authentication credential.”

Full Error Message:
Error while creating new document. Error message: Error: 401. Error description: { “error”: { “code”: 401, “message”: “Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See”,”status”: “UNAUTHENTICATED” } }

-You may get this error message when trying to generate a document though your google drive has not  been connected and app unauthorized. Or it needs to be reconnected after package install update or major change in A5 Documents process.

How to resolve:
-First you need to make sure this user is an assigned app user by following our activation instructions.
-Second, you want to decide if you would like each app user to authorize their own drive or if you would like only one Salesforce user to authorize the app and the google drive for ALL app users to generate documents too. See this article for more detail on this optional feature.
-If you would like each user to authorize the app and their own drive, each user will need to go to “A5 Documents Configuration” tab and click “Grant access.” Then you will follow the steps to connect your google drive account you would like to use to generate documents. You can click here if you need to create a new gmail/google account.

My colleague who configured the app is leaving company, how do I make for a smooth transition for document generation?

We suggest to test under the new user prior to original app user leaving if possible. This will make for a smoother transition between users and google drive settings:
1. Open up current google doc templates that are being used in active document actions (can access by click on the “here” button from above the embedded template builder within document action or find the template directly on your company drive if applicable).
2. Notice the sharing/permission sets on original google doc templates made by colleague if you would like to keep it the same with new template (keep original template IDs copied on clipboard or place in folder on computer or google drive).
3. Go to “File” and then “Make a Copy” of each of your google doc template and save it to the new users google drive so that they become the owner of the new google doc templates.
4. Replace the current template IDs with the new IDs in each related document action. inOnce you have the new templates copied to your google drive,
5. Go to A5 Documents Configuration tab to authorize app and google drive to be used with new user and new template IDs already in document action(s) and make sure your user is an active assigned user to the app following end of our activation instructions).
6. Then test document generation under new user. If you find an error message, do a search in our Knowledge Base to see if you can find related error article. If you are unable to find and not sure what issue is, submit a case to support with more detail and provide login access to A5 Apps.
7. Have new user review any needed support articles for more detail on setup and instruction (begin with “Getting Started” section).

Use Case: Can I merge an image into header of each related list table?

Consulting Reply:
You can “insert” a header or footer into document and can merge fields and images there. You can also insert an image merge field into top of table though we don’t think there is a way to make the table header repeat on each page as the related list repeats.  One thing we can try to figure as possible option is allowing the page to break and controlling that and merging other tables filtering on the quote line items.  Such as maybe calculating the characters or lines in the description field and using that to try to group the line items into pages and merging them in groups for each page.  There may be something else in Google docs functionality to try to just get it to repeat a header for the table on each page.

I am using “download file” feature in A5 Documents but do not see the document go to my Downloads folder on computer. What am I doing wrong?

It is mandatory that you allow Pop Ups from Salesforce domain as browsers are interpreting this “download” action as a popup in new window. If you are’t sure if your pop ups are already approved, you will notice that when you attempt to generate a document for download to your computer, there is usually an indication that a pop up was blocked and you have the option to approve that URL for the future. Once the URL is approved, you should not have to do this step again.

To check your pop-up settings in Chrome Browser: chrome://settings/content/popups?search=pop. You will want to make sure you allow Pop Ups from Salesforce and/or A5 Documents domain.