"Create PDF" doesn't work

Hello,

ich made my first AppSheet App and I am very satisfied with it.

The only problems are the details.

I created a Bot to Create a PDF File, but it doesn’t work. Before that, it worked, but I changed it to get some buttons, and now I ran into issues.

These were my steps:

  1. I created a new column [FILE] and set it to Type “File”.

  2. Than I created a new Action for a Button and set it to: “CONCATENATE(”/Folderpath/“, [NAME], “.pdf”)” and Behavior to ISBLANK([FILE])

  3. Last step I created a Bot with the Event Data Change Type - “Updates” and the Condition: NOT(ISBLANK([FILE]))

  4. Run the Process Step with Create a file PDF and File Name Prefix : CONCATENATE([NAME])

Any tipps?

As I understand it, you want to trigger the Bot that creates the PDF by tapping a button. It also seems you are attempting to pre-set the file name in the [FILE] column so that when the PDF is created, tapping on the [FILE] column will open the PDF.

You can get things to work like what you intend but there are some changes you need to make.

  1. Note that on the Bot step that creates the PDF File there are separate fields for File Folder Path and File Name Prefix.
    a) Set the File Folder Path to simply “Folderpath” - no slashes. NOTE: this is a folder created under the “Default app folder”
    b) Set File Name Prefix to simply [Name] - no CONCATENATE needed and I assume this IS your file prefix.
  2. AppSheet by default adds a Timestamp property to prevent duplicate file names. You will need to turn this off by setting the “Disable Timestamp” property to ON in the Bot step just underneath the File Name Prefix field.

NOTE: While there is nothing wrong with “NOT(ISBLANK([FILE]))”, the simplified version of it is “ISNOTBLANK([FILE])

I believe if you have things set like the above it will work fine. Just note that if you were to somehow re-run that row and re-create the SAME Filename, it will be a duplicate of an already existing file. Google retains dups for version control and this can sometimes cause a delay in the updated file reaching the app. I recommend never creating dups but instead version the file names by adding version numbers to it - e.g. Name_1, Name_2, Name_3…etc.

I hope this helps!