How to load pdf file from assets in webview

anyone plz help me how to load any pdf from assets in our webview.
plz suggest me how to do that
every help will be appreciated

thanks in advance

Hello
1st import your pdf file in the kodular
2. Create the text box and 1 button for showing the PDF
3. Add the activity starter for show a pdf
( On the activity starter blocks is
1.add data type url and write application/PDF
2.add action android.intent.action.View
3.Data uri give your file name on the box your are import In kodular
It’s working 100 % give me :white_check_mark: this mark
Thank You

1 Like

bro i want to load that in webview in app not to open any other app

Means you will be add a PDF in your website and after you show in your and from the webview

You can try using the url as

file:///android_asset/Yourfile.pdf

Note tgat the upper url will not work in test mode.

i tried but it didn’t work
can u help me with a aia

Can you describe more your app how you actually need in your app webview with pdf or only show all PDF in app

i want my apps to use pdf from assest and then to display in webview of my app
i dont want to use any other app to open my pdf i want to show it in webview in my app

This video will be help you
Thank You :white_check_mark:

2 Likes

i want to show in my app only not any other
i already watched it

Then this is the only way with in your app App Inventor Extensions: Pdf | Pura Vida Apps.

/Boban

2 Likes

Did you get your answers?

1 Like