CustomWebView : An extended form of Web Viewer

It's StopLoading actually.
image

Thanks for reply, it's still not working tho, now the initial website doesn't load at all, it only works when i add the original website as the url in the block, how can i add multiple urls to the block? I want to add both the original website and the other one as this might work

Quite easy.

Thanks alot for your help, i really appreciate...this fixed it

Hello, i need help pls anyone, I used these blocks to run downloads in my app but the downloaded filename is just the extension .mp4 how do i make it show the right name?

GuessFileName is the best way to get file name from url.
But if it does not work as expected then what you can do it to split url at / and select last item of the list.

Oh! No Url doesn't have file name :cry:

Then in that case, since you have file extension (mp4) so you can make a random file name and suffix file extension to it.

I don't know how to go about this tho, i don't understand yet, but about extracting name from the url, is it from the final download url?

httpss://storage-31.dsto.store/46e4084471cadb48f887a17/EP.1.v0.1699238407.360p.mp4?token=DVRBOxMmOI684h5GNNMCzw&expires=1699255181&id=394049&title=

I added an extra s because mp4 file was embeded here

This is the direct download link of an mp4 and the title starts from EP.1.VO, can the name be collected from this section ?

Hello, thank you all for creating this incredible community. I have a question which is How to solve the below issue:

Runtime Error

Argument #2 (com.google.appinventor.components.runtime.Table...) to 'com.sunny.CustomWebView.CustomWebView.CreateWebView(com.google.appinventor.components.runtime.HVArrangement,int)' has wrong type (com.google.appinventor.components.runtime.TableArrangement) (expected: com.google.appinventor.components.runtime.HVArrangement)
Note: You will not see another error reported for 5 seconds

Most probanly you try to create webview using as container a table arrangement instead of a Vertical Arrangement

WebviewHArrangement - accepts horizontal arrangement
WebviewVArrangement - accepts vertical arrangement

image

2 Likes

Hi, I'm trying to download the contents of the web portal I created (and now I wanted to create its app). I tried to download the payrol but despite or following the guides, if I click on the button nothing happens and the page zoom there is no way to remove it. how can I do? I attach the blocks that I inserted following your examples

What happens when you pass Download as downloadDir ?

Nothing is happening. I press the button to download the file but nothing happens.

Post aia.

trai@gmail.com
abc123456

last icon left (document)
JSMARTED.aia (109.8 KB)

You are using WebViewer and then expecting CustomWebView to download files.
Strange.

and what can I do for my case? you understand I'm new. I only ask that from my site it is possible to download files that do not always have a precise address. I don't want to rebuild an entire application, but just make sure that the files can be downloaded from the site and that the zoom is removed.

You should use this extension then.

1 Like

Thank you for this very useful extension, which I have been using for some time for my study projects and applications.
Now I have a little problem with a project:
when in a page open in the Web View there is a link that requires the opening of another window, I would like to open the window not within the application, but externally with the device's browser, so as to leave the application with the window containing the source page.
I know how to do it, i.e. with ActivityStarter, but I can't start it because I don't have an event that makes the URL available to pass to the Activity Starter.
The "OnNewWindowRequest" event would be ideal, but there is no URL parameter to pass to the functions to start the Activity. Would this be perfect to implement, or do you have a better solution?
For example, the Web Viewer built into App Inventor has an event called "BeforePageLoad" which would be equally perfect for what I would like to do, but I can't use that component because it lacks other essential features and configurations.
Thanks again for your work.