How to make the whole EditText white?

I need to create absolutely white EditText field. If I make it visibility GONE it doesn’t work. So I decided to make it just white. I use it just to read data from another devise and then save it to some variable. I wrote this:

    final EditText input = new EditText(mContext);
    LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(0, 0);
    input.setLayoutParams(lp);
    input.setInputType(InputType.TYPE_CLASS_NUMBER);
    input.setTextColor(mContext.getResources().getColor(R.color.white_two));
    alertDialog.setView(input);

But bottom line and cursor are still visible and I can’t find methods to change it. Or maybe you know how to get data from invisible view.
One other point – this view is in the AlertDialog, so if it’s invisible Cancel button clicks by itself. I can use only EditText, because I have a device which gets some data and can transfer it to android app and it only can set this data to EditText.

try this

input.setBackgroundResource(android.R.color.transparent);// remove underline from Edittext using this
input.setFocusable(false);
input.setCursorVisible(false);// hide the cursor from edittext

sample code

    final EditText input = new EditText(mContext);
    LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(0, 0);
    input.setLayoutParams(lp);
    input.setInputType(InputType.TYPE_CLASS_NUMBER);
    input.setTextColor(mContext.getResources().getColor(R.color.white_two));

    input.setBackgroundResource(android.R.color.transparent);// remove underline from Edittext using this
    input.setFocusable(false);
    input.setCursorVisible(false);// hide the cursor from edittext
    alertDialog.setView(input);

You can use this

 <android.support.v7.widget.AppCompatEditText
            android:id="@+id/username"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:backgroundTint="@color/white"
            android:drawableLeft="@drawable/user_icon"
            android:drawablePadding="5dp"
            android:textColor="@color/white"
            android:textCursorDrawable="@null"
            android:drawableTint="@color/white"
            android:hint="username"
            android:textColorHint="@color/white" />

If you don’t want to show your edit_text, you can make it’s height or width as zero.