title: How to get current View in Service
body: <p>I would like to send phone screen to desktop. (using socket) like a Mobizen App </p>
  
  <p>First, I need to take phone screen.</p>
  
  <p>I knew how to save the Activity screen.
  like this.</p>
  
  <pre><code> View v1 =L1.getRootView();
               v1.setDrawingCacheEnabled(true);
               Bitmap bm = v1.getDrawingCache();
  
               FileOutputStream out = null;
               try {
                   out = new FileOutputStream(Environment.getExternalStorageDirectory().getPath()+"/capture.png");
                   bm.compress(Bitmap.CompressFormat.PNG, 100, out); // bmp is your Bitmap instance
                   // PNG is a lossless format, the compression factor (100) is ignored
               } catch (Exception e) {
                   e.printStackTrace();
               }
  </code></pre>
  
  <p>but This is only possible Activity.</p>
  
  <p>I would like to capture a screen in the background as a service.
  And current screen of phone will send to desktop.</p>
  
  <p>So, How to get current View in Service?</p>
  
  <p>Thanks regards.</p>