Link of pdf on list picker

hello everyone, I'm trying to make a list of pdf file from my google sheet where users can download or view. I dont know what format to use in using web1 as I have only used csv on my past projects. thanks in advance..

https://drive.google.com/uc?export=download&id=FILE_ID

If you use the above link then your each sheet will be download as pdf

1 Like

thank you so much sir, do i need to modify file ID? never had experience on using id=file_id before, only gid=

Open specific Google sheet in a webviewer

since i cant seem to work on my previous idea, im downgrading to simply display specific google sheet in webviewer, can someone help me with this good sirs?i tried to put the gid id but still shows the whole google sheet. thanks

Post a link to the sheet, and tell us more about what part you want to show.

Do you need to update the sheet?

thank you for your response sir, i have a google sheet with supposed 3 tabs, i would like to show a column of data with link that they can open or download the link. this 3 tabs will specifically accessed from another screen whether they will open tab 1 or tab 2 or tab 3.

Why you need to show the sheet when you just want to show the sheet column content in a list view?

Fetch the data from sheet using web or any google spreadsheet reader and show it in a list view.

When user selects any list item then open the selected link as you want.

Should we start again?

  • Is your primary objective to provide a listpicker/listview that users can select from to either view or download a pdf?

  • Are all your pdf files and your google sheet set to "Anyone with the link" on google drive to allow access?

  • Why do you have 3 tabs on your google sheet, do you only need to access one that holds the filenames and links ? Or do you need to access all three ?

  • What method were you intending to use to "view a pdf" in your app ?

  • To where on your device did you want to download pdf files,
    Download ? (for use by other apps)
    ASD ? (just for use by your app)
    Other ?

  • Show an example of your google sheet data

sorry sir i posted in the wrong topic..this is my first idea, if its possible to use list view in selection of posted links on a specific column of a google sheet.

sorry sir i posted in the wrong topic. i had given up on the original idea to have a listview of my posted data with link where it can be viewed or download via webviewer(its the only way i know for the moment). so the alternative i had in mind is to simply display the specific column where the data with link will be shown via webviewer so they can view it or download it. the idea is to create a database of scanned daily attendance where the user can pick what day they want to view via listpicker(if possible)or webviewer as alternate. sorry i cant provide google sheet for it is an idea for now. but i already made a sample sheet where i linked a pdf file that is shared "anyone with the link" and its google sheet. and it is important to separate 3 columns with different pdf links for regular employees and contractuals

Have you considered adding a column to the sheet identifying the category of worker (regular employee/ contractual)?

That changes the problem from juggling sheets/tabs to filtering rows.

1 Like

Like so:

image

You can then use gviz to query the google sheet for employees only, not employees, or all...

Here a blocks example for employees only (I use a label to display the data, for actual use one would convert to a list):

(Note that the tickbox in the sheet is a boolean, so you do not have to use single quotes around the TRUE)

1 Like

I would have gone with category name instead of true false, to guard against the possibility of third or fourth categories.

1 Like

thank you for input and guidance sir. but this is the idea i have, on the first screen the user pick 1 of the 3 choices, then on the next screen, a list picker can display the available dates as it is the name of the link and they can simply open or download the pdf file they choose an item from the list. but i have no idea how to make that possible. so the alternative is to just show the specific sheet with just the columns A and B via webviewer. thank you for always answering sir.

You are not making it very obvious (well ,to me...) what it is you want.

Which three choices ?

The name of the link to what ?

What items, what list ?

Why not show us examples of the data in each of the three scenarios above, which may help us get you there.

sorry sir this is just an idea at the moment, in the 1st screen there are 3 buttons to choose from, "Regular Employee","Contractual","Job Order"

as they chose from the 1st screen, the appropriate screen will open and a list picker can display the column of the SS i shared, and once they choose from the list, it will open the pdf file to view.

the other elements of the project i already have an idea sir, the thing that i need guidance is showing the pdf file from the list picker, but i know its not possible by converting the format of google sheet table to csv. that is why the alternative to my idea is to simply open the specific sheet and column in a webviewer so by default it can show or download the pdf file. hope it makes sense

That makes more sense, and can fit with what we have previously suggested.

You will find it much easier to use a single sheet, and store all your data there, you can break it out in the app as required.

image

What else (columns) needs to be in each row for each item? (e.g. date ?)

Also:
I asked earlier in the topic how you intend to view the pdf files, and where they might be downloaded to ?

thank you so much sir for this, but im thinking of naming the filename into days of the month since it will change every month, like this month of july the weekdays will be like july 2-6 and so on. that is my option is to put the categorized employment into different columns, or sheet if not possible. so that the list picker will show July 2 going to july 31, and on the file ID i will put the pdf file link.

the only thing i currently know is webviewer can show the pdf file if called directly that is why i need guidance to options i can approach with my idea sir.. thank you once again

Here is a simple example, based upon what I understand so far:

SPREADSHEET
image

BLOCKS

VIDEO

AIA
pdfPicker.aia (3.9 KB)

  • note: I have only used one pdf file, duplicated with different file names...:wink:

  • you will also see that I have "cheated" a bit, by using the ImageName as a text item to store the file ID.

  • the dates are text items, not date numbers, and in alpha-numeric format so that they can be sorted.

If you want to use the Download button in the pdfviewer, then you will need the webviewextra extension to facilitate the download. By default, this will download the file to your Download directory.

2 Likes

this is perfect sir seeing the video.. will slice and dice this to learn from it.. thank you so much sir as always!