I have made a main Dialog class on which I send the layout ID and shows the layout as a Dialog now when I send the layout from calling class it pop
There you go:
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(id);
Button signInbutton=(Button)findViewById(R.id.signInButton);
signInButton.setOnClickListener(this);
Button closebutton=(Button)findViewById(R.id.closeButton);
closeButton.setOnClickListener(this);
}
@Override
public void onClick(View v) {
if(R.id.closeButton == v.getId()) {
closeButton(v);
} else {
// do the same for signInButton
}
}
Suggest you learn the basic beforehand.