本文介绍了设置的EditText与"网址" inputType的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图让一个的EditText 这样,当我点击它包含的.com出现一个键盘,因为URL将被intered到的EditText 。我试图用这样的:安卓inputType =textUri,但它不工作。我该怎么做呢?

I am trying to make an EditText such that when i click it a key board containing ".com" appears because a url is to be intered into the EditText.I tried to use this: android:inputType="textUri" but it is not working. How do i do it?

推荐答案

试试这个

<EditText
        android:id="@+id/edt"
        android:layout_height="wrap_content"
        android:layout_width="wrap_content"
        android:inputType="textWebEmailAddress"
        />

安卓inputType =textWebEmailAddress使用此属性为。

android:inputType="textWebEmailAddress"use this property for that.

这篇关于设置的EditText与&QUOT;网址&QUOT; inputType的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

05-27 03:09
查看更多