The method setPositiveButton(int, DialogInterface.OnClickListener) in the type AlertDialog.Builder i
参考资料:
http://blog.csdn.net/competerh_programing/article/details/7377950
在创建Dialog的时候,出现:
The method setPositiveButton(int, DialogInterface.OnClickListener) in the type AlertDialog.Builder i
的错误提示。解决方法:
将代码:
bulider.setPositiveButton("确定", new OnClickListener() {
换成:
bulider.setPositiveButton("确定", new DialogInterface.OnClickListener() {
即可解决问题
同样,.setNegativeButton()也如此处理即可
The method setPositiveButton(int, DialogInterface.OnClickListener) in the type AlertDialog.Builder i的更多相关文章
- The method setPositiveButton(int, DialogInterface.OnClickListener) in the type AlertDialog.Builder is not applicable for the arguments
The method setPositiveButton(int, DialogInterface.OnClickListener) in the type AlertDialog.Builder i ...
- The method replace(int, Fragment, String) in the type FragmentTransaction is not applicable for the arguments (int, SettingFragment, String)
The method replace(int, Fragment, String) in the type FragmentTransaction is not applicable for the ...
- android-The method findViewById(int) is undefined for the type ContactMainFragment报错
@Override public void onViewCreated(View view, Bundle savedInstanceState) { super.onViewCreated(view ...
- must implement the inherited abstract method DialogInterface.OnClickListener.onClick(DialogInterface, int)问题
依照视屏编写代码如下 class MyButtonListener implements OnClickListener{ @Override public void onClick(View v){ ...
- .replace(R.id.container, new User()).commit();/The method replace(int, Fragment) in the type FragmentTransaction is not app
提示错误:The method replace(int, Fragment) in the type FragmentTransaction is not applicable for the arg ...
- 错误:The method replace(int, Fragment) in the type FragmentTransaction is not applicable for the arguments (int, MyFragment)
Fragment newfragment =new MyFragment();fragmentTransaction.replace(R.layout.activity_main,newfragmen ...
- The method setOnClickListener(View.OnClickListener) in the type View is not applicable
开始学习 android 了,学习的是高明鑫老师的android视频教程(android视频教学). 学到第八讲时, 在写动态设置时报错: The method setOnClickListener( ...
- new DialogInterface.OnClickListener()报错的解决办法
在项目过程中 new DialogInterface.OnClickListener()总是报下面的错 Illegal qualified access from the type parameter ...
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory
The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory 这是由于项目里面的一些 ...
随机推荐
- POJ 3414 Pots (dfs,这个代码好长啊QAQ)
Description You are given two pots, having the volume of A and B liters respectively. The following ...
- delphi xe 正则表达式
Delphi XE 中自带了正则表达式的处理类TRegEx,包含在单元 RegularExpressions,使用时要uses 一下. TRegEx 是一个结构 ,使用时不用释放.他内部还是 ...
- 存储-docker volume 生命周期管理(14)
volume 生命周期管理 - 每天5分钟玩转 Docker 容器技术(44) Data Volume 中存放的是重要的应用数据,如何管理 volume 对应用至关重要.前面我们主要关注的是 volu ...
- [CSP-S模拟测试]:蛋糕(区间DP)
题目传送门(内部题34) 输入格式 第一行,一个正整数$n$.第二行,$n$个正整数$a_i$,保证$a_i$互不相等. 输出格式 一行一个整数表示间宫卓司得到的蛋糕大小总和的最大值. 样例 样例输入 ...
- PostgreSQL9.6的新特性并行查询
PostgreSQL在2016年9月发布了9.6版本,在该版本中新增了并行计算功能,目前PG支持的并行查询主要是顺序扫描(Sequencial Scans),并且支持部分链接查询(join)和聚合(a ...
- Tomcat负载均衡、调优核心应用进阶学习笔记(四):JVM调优
文章目录 概述 **JVM管理的内存段可分为两大类:线程共享内存和线程私有内存** Java Heap SIze Options The memory structure of a JVM proce ...
- 基于MFC的Media Player播放器的制作(3---功能实现)
| 版权声明:本文为博主原创文章,未经博主允许不得转载. 下面我们试试一下,按下退出Button退出播放器的功能: 首先,我们双击退出Button按钮,就会弹出下图的框: 上面的弄好之后我们就实现 ...
- Vue.js实现一个SPA登录页面的过程【推荐】
地址:https://www.jb51.net/article/112550.htm vue路由跳转时判断用户是否登录功能的实现 地址:https://www.jb51.net/article/126 ...
- leetcode.矩阵.73矩阵置零-Java
1. 具体题目 给定一个 m x n 的矩阵,如果一个元素为 0,则将其所在行和列的所有元素都设为 0.请使用原地算法. 示例 1: 输入: 输出:[ [ [1,1,1], [1,0,1], [ ...
- Struts2的Action访问
● 示例项目结构 ● demo1.jsp <%@ page language="java" import="java.util.*" pageEncod ...