1.日期选择器

<DatePicker
android:layout_width="wrap_content"
android:layout_height="wrap_content"></DatePicker>

2.时间选择器

<TimePicker
android:layout_width="wrap_content"
android:layout_height="wrap_content"></TimePicker>

3.计时器

其中常用的五种方法

(1)setBase()  设置计时器的起始时间

(2)setForma()  设置计时器的显示时间格式

(3)start()  指定开始计时

(4)stop() 指定停止计时

(5)setOnChronometerTickListene()   为计时器绑定事件监听器,当计时器改变时触发该监听器

<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity"> <Chronometer
android:id="@+id/jishi"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:format="以用时间%s"
/> </android.support.constraint.ConstraintLayout>

最新文章

  1. js 获取当前日期时间3种格式化方法 yyyy-mm-dd hh:MM:ss
  2. 《构建之法》第8、9、10章 读书笔记和Sprint总结
  3. :( Call to a member function Table() on a non-object 错误位置
  4. hadoop 入门实例【转】
  5. 慕课网-安卓工程师初养成-4-4 Java条件语句之嵌套 if
  6. gdb 技巧
  7. Bnuoj-29359 Deal with numbers 线段树
  8. Google Play和基于Feature的过滤
  9. IOS开发之----四舍五入问题
  10. NSIS:应用软件自动升级功能的探索与实践
  11. MongoDB数据模型(三)
  12. spring mvc获取绝对路径的几种方法
  13. 使用genism训练词向量【转载】
  14. Centos7.3 编译安装GDAL以及Python的GDAL包
  15. CentOS下使用VirtualBox 安装 Windows虚拟机的简单方法
  16. Android 屏幕手势滑动中onFling()函数的技巧分析
  17. Android tesseract-orc之扫描身份证号码
  18. Android.mk遍历子目录所有文件
  19. 如何防御mimikatz致敬Mimikatz攻防杂谈学习笔记
  20. Jmeter(十一)_针对响应信息不明确的接口做关联

热门文章

  1. Linux测试环境简单使用教程
  2. Topics类型配置
  3. pico g2 触摸板手柄射线检测---for unity
  4. LoadRunner参数传递给参数
  5. 在VMware中如何清理多余的空间
  6. 一次DB故障引起的反思和MySQL Operator选型
  7. 在cmd中启动tomcat
  8. BZOJ1257 [CQOI2007]余数之和 (数论分块)
  9. Pycharm学习记录---同一目录下无法import明明已经存在的.py文件
  10. angularJS 传参的四种方法