i used fileselectActivity for select different file path and intent back to mainActivity ,the intent will jump multiple times,because i have to insert multiple filepath to Edittext,the problem is now i can't able to get the Edittext value and length.

```
Here is my code.

    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.decryption_activity);
        privatekeypathedit = (EditText) findViewById(R.id.privatekeypathEdittext);
        targetfilepathedit = (EditText) findViewById(R.id.targetfilepathEdit);
        privatekeypath(); //Button
        targetfilepath();//Button
        startdecryption();//Button

        Intent intent = getIntent();
        String filepath = intent.getStringExtra("filepath");

        Toast.makeText(this, privatekeypathedit.getText(), Toast.LENGTH_LONG).show();//Here is empty
        Toast.makeText(this, targetfilepathedit.getText(), Toast.LENGTH_LONG).show();//Here is empty

        if (privatekeypathedit.getText().length() == 0) {//i think here still not working

            privatekeypathedit.setText(filepath);

        } else if (targetfilepathedit.getText().length() == 0) {

            targetfilepathedit.setText(filepath);

        }

         System.out.println("Test##############"+privatekeypathedit.getText().toString());//null
         System.out.println("Test##############"+targetfilepathedit.getText().toString());//null

    }

```

This is my layout file.

```
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical" >

    <EditText
        android:id="@+id/privatekeypathEdittext"
        android:layout_width="match_parent"
        android:layout_height="wrap_content">
       <requestFocus />

    </EditText>

    <Button
        android:id="@+id/publickeyselectButton"
        style="?android:attr/buttonStyleSmall"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:text="Select private key file(.pfx)" />

    <EditText
        android:id="@+id/targetfilepathEdit"
        android:layout_width="match_parent"
        android:layout_height="wrap_content" />
       <requestFocus />

    <Button
        android:id="@+id/targetfileselectButton"
        style="?android:attr/buttonStyleSmall"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:text="Select target file" />

    <EditText
        android:id="@+id/privatekeypasswordedit"
        android:layout_width="match_parent"
        android:layout_height="wrap_content" />
         <requestFocus />

    <Button
        android:id="@+id/startdecryptionButton"
        style="?android:attr/buttonStyleSmall"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:text="Start Decryption" />

</LinearLayout>

```

fileSelectActivity

```
    private void onFileClick(Option o)
    {  

        Toast.makeText(this, "You selected "+o.getName(), Toast.LENGTH_SHORT).show();
        Intent intent = new Intent(selectddecrypfile.this,decryptActivity.class);
        intent.putExtra("filepath", o.getPath());
        startActivity(intent);

    }

```