title: how to implement vertical scroll on pop-up window in android?
body: <p>I've tried with a piece of code but it is not displaying vertical scroll bar. my code is pasted below:</p>
  
  <pre><code>     public void init() {
          popupButton = (Button) findViewById(R.id.textview1);
          popupText = new TextView(this);
          insidePopupButton = new Button(this);
          layoutOfPopup = new LinearLayout(this);
          LinearLayout lt=new LinearLayout(this);
          view=new ScrollView(this);
          insidePopupButton.setText("OK");
          popupText.setText("This is Popup Window.press OK to dismiss   it.");
          popupText.setBackgroundColor(Color.WHITE);
          popupText.setPadding(0, 0, 0, 20);
          layoutOfPopup.setOrientation(1);
          lt.addView(popupText);
          layoutOfPopup.addView(insidePopupButton,350,35);
  
          layoutOfPopup.setBackgroundColor(Color.BLACK);
          view.addView(lt);
          layoutOfPopup.addView(view);
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/k19jE.png" alt="enter image description here">
  Thank you in advance..:)</p>