I have a layout in xml with attributes height:700dp and width:300 dp. How I can change size this layout in code? I try something like this but I got NullPointer:
setContentView(R.layout.log_in_dialog_view);
view = findViewById(R.layout.log_in_dialog_view);
lp = view.getLayoutParams();
lp.height = 200;
lp.width = 200;
view.setLayoutParams(lp);