R RicardoSantanna Member Licensed User Longtime User Sep 8, 2015 #1 Hello averyone! I don't wanna show my URL inside webview when it receives connection error. How to do that? using reflection or not. thx Last edited: Sep 8, 2015
Hello averyone! I don't wanna show my URL inside webview when it receives connection error. How to do that? using reflection or not. thx
Erel B4X founder Staff member Licensed User Longtime User Sep 9, 2015 #2 You can use HttpUtils2 to access the url. Only if Job.Success is true then load it into WebView. Upvote 0
R RicardoSantanna Member Licensed User Longtime User Sep 9, 2015 #3 Erel said: You can use HttpUtils2 to access the url. Only if Job.Success is true then load it into WebView. Click to expand... Ty so much Erel, i will try and give to you a feedback. Upvote 0
Erel said: You can use HttpUtils2 to access the url. Only if Job.Success is true then load it into WebView. Click to expand... Ty so much Erel, i will try and give to you a feedback.
warwound Expert Licensed User Longtime User Sep 9, 2015 #4 Or look at the solution on this page: https://www.b4x.com/android/forum/threads/webview-error-404-source-html-body.57906/#post-364647 Upvote 0
Or look at the solution on this page: https://www.b4x.com/android/forum/threads/webview-error-404-source-html-body.57906/#post-364647
R RicardoSantanna Member Licensed User Longtime User Sep 9, 2015 #5 warwound said: Or look at the solution on this page: https://www.b4x.com/android/forum/threads/webview-error-404-source-html-body.57906/#post-364647 Click to expand... Sry warwound, but i already have a Webview in my layout, must i have to associate wextras with my webview or not? can you write a simple start example to me? what i have to create , initialize and associate pls? thank you so much. Upvote 0
warwound said: Or look at the solution on this page: https://www.b4x.com/android/forum/threads/webview-error-404-source-html-body.57906/#post-364647 Click to expand... Sry warwound, but i already have a Webview in my layout, must i have to associate wextras with my webview or not? can you write a simple start example to me? what i have to create , initialize and associate pls? thank you so much.
R RicardoSantanna Member Licensed User Longtime User Sep 10, 2015 #6 warwound said: Or look at the solution on this page: https://www.b4x.com/android/forum/threads/webview-error-404-source-html-body.57906/#post-364647 Click to expand... My WebViewExtras never fires any Event, do you know why ? Upvote 0
warwound said: Or look at the solution on this page: https://www.b4x.com/android/forum/threads/webview-error-404-source-html-body.57906/#post-364647 Click to expand... My WebViewExtras never fires any Event, do you know why ?
warwound Expert Licensed User Longtime User Sep 10, 2015 #7 RicardoSantanna said: My WebViewExtras never fires any Event, do you know why ? Click to expand... Upload your non working code and i'll take a look. Upvote 0
RicardoSantanna said: My WebViewExtras never fires any Event, do you know why ? Click to expand... Upload your non working code and i'll take a look.
R RicardoSantanna Member Licensed User Longtime User Sep 10, 2015 #8 take a look pls. thx Attachments eexponews.zip eexponews.zip 38.5 KB · Views: 431 Upvote 0
R RicardoSantanna Member Licensed User Longtime User Sep 10, 2015 #9 Erel said: You can use HttpUtils2 to access the url. Only if Job.Success is true then load it into WebView. Click to expand... I need to use httpjob.Download("someurl") after, i test if Job.Success , then ... ? how can i load data from httpjob to webview ? thx a lot. Upvote 0
Erel said: You can use HttpUtils2 to access the url. Only if Job.Success is true then load it into WebView. Click to expand... I need to use httpjob.Download("someurl") after, i test if Job.Success , then ... ? how can i load data from httpjob to webview ? thx a lot.
Erel B4X founder Staff member Licensed User Longtime User Sep 10, 2015 #10 RicardoSantanna said: how can i load data from httpjob to webview ? Click to expand... Just call WebView.LoadUrl with the same url. Upvote 0
RicardoSantanna said: how can i load data from httpjob to webview ? Click to expand... Just call WebView.LoadUrl with the same url.
warwound Expert Licensed User Longtime User Sep 10, 2015 #11 RicardoSantanna said: My WebViewExtras never fires any Event, do you know why ? Click to expand... Sub WebViewExtras1_ReceivedError should be named Sub WebViewClient1_ReceivedError Martin Upvote 0
RicardoSantanna said: My WebViewExtras never fires any Event, do you know why ? Click to expand... Sub WebViewExtras1_ReceivedError should be named Sub WebViewClient1_ReceivedError Martin
R RicardoSantanna Member Licensed User Longtime User Sep 11, 2015 #12 Hi Guys. ReceivedError never fired, i solved my problem using: Sub CheckConnection As BooleanDim r AsReflector r.Target = r.GetContext r.Target = r.RunMethod2("getSystemService", "connectivity", "java.lang.String") r.Target = r.RunMethod("getActiveNetworkInfo") If r.Target <> NullThen Return r.RunMethod("isConnectedOrConnecting") EndIf Return False End Sub Thank you all for help-me. Upvote 0
Hi Guys. ReceivedError never fired, i solved my problem using: Sub CheckConnection As BooleanDim r AsReflector r.Target = r.GetContext r.Target = r.RunMethod2("getSystemService", "connectivity", "java.lang.String") r.Target = r.RunMethod("getActiveNetworkInfo") If r.Target <> NullThen Return r.RunMethod("isConnectedOrConnecting") EndIf Return False End Sub Thank you all for help-me.