将值从android中的活动传递到webview [英] passing value to webview from an activity in android

查看:219
本文介绍了将值从android中的活动传递到webview的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一项活动可以对用户输入产生某种结果方面的尊重.

I have one activity to produce some result respect with user input.

我的xml页面就像一个文本视图,按钮和一个webview.

my xml page is like one text view, button and a webview.

当用户输入某个日期并单击按钮然后生成一个值时. 同样,在加载页面时,Web视图会从资产文件夹加载本地html页面,并显示一些默认值.

when user input some date and clicks the button then generate one value. also when loading page the web view loads a local html page from asset folder and its showing some default value.

当新值产生对按钮单击的尊重时,我需要什么,我还需要更改html页面的值.

what my need is when new value generates respect with button click i need to change the html pages value also.

如何将价值传递给网络视图. pblm是我不想在加载时将值传递给我,我需要在某个中间阶段传递值,因为默认情况下它已经显示了一个值.

How to I pass value to web view. pblm is I don't want to pass value to while loading I need to pass value at some intermediate stage because default its already showing one value.

如何做到这一点.如果有人可以提供帮助,我将不胜感激.

how to make this. I appreciate it if anyone can help.

推荐答案

我对您的问题有一个小疑问.抱歉,您实际上是想实现此目标吗?基于您的值,您是否要在Web视图中加载单独的html文件,还是要更改默认情况下已在Web视图中加载的网页中的任何值?可能是此链接对您有用 http://android-er .blogspot.in/2011/10/call-javascript-inside-webview-from.html

I have a small doubt regarding your question. sorry ,wht actually u want achieve ?based on ur value do u want to load a seprate html file in the webview or u want to change any value in the web page which is already loaded in the webview by default.May be this link will be useful for you http://android-er.blogspot.in/2011/10/call-javascript-inside-webview-from.html

这篇关于将值从android中的活动传递到webview的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆