Latest News

Source Code Widget Edittext Dengan Aplikasi Android




* widgetEditText.java */ :
Sbb:
package com.example.widgetedittext;

import android.support.v7.app.ActionBarActivity;
import android.os.Bundle;
import android.widget.EditText;

public class WidgetTextActivity extends ActionBarActivity {

      @Override
      protected void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.activity_widget_text);
            EditText fld=(EditText)findViewById(R.id.field);
            fld.setText("Contoh WidgetEditText.."+ " properti singleline=false. "+ "tulisan dapat dirubah "+ "seperti ini.");   
      }
}


/* Widget EditTextActivity.xml */
 Sbb :
<?xml version="1.0" encoding="utf-8"?>
<EditText
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:text="EditText"
    android:id="@+id/field"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:singleLine="false">
 </EditText>

0 Response to "Source Code Widget Edittext Dengan Aplikasi Android"