within my main activity I have the following code:
EditText usernameText;
EditText passwordText;
public void sendLogin (View loginview){
Intent i = new I
1. For sending usernameText and passwordText to NetworkService do this....
Intent i = new Intent(Your_Class_Name.this, NetworkService.class);
i.putExtra("username", usernameText.getText().toString());
i.putExtra("password", passwordText.getText().toString());
startService(i);
2. To receive the data in NetworkService do this....
Intent intent = getIntent();
String userName = intent.getExtras().getString("username");
String password = intent.getExtras().getString("password");