title: How to save recorded video in custom folder in android
body: <p>How to save a video in a custom folder and not in default folder so this is my code ,but when i switch off recording it just hangs</p>
  
  <pre><code>        File dir = new File(Environment.getExternalStorageDirectory()+ "/FutureCopyright");
              if (dir.exists() &amp;&amp; dir.isDirectory()) {
                  // do something here
              } else {
                  // create dir here
                  dir.mkdir();
              }
              System.out.println(1);
              Intent cameraIntent = new Intent(android.provider.MediaStore.ACTION_VIDEO_CAPTURE);
              System.out.println(2);
              cameraIntent.putExtra(android.provider.MediaStore.Video.Media.MIME_TYPE,"video/3gp");
              System.out.println(3);
              cameraIntent.putExtra(android.provider.MediaStore.EXTRA_DURATION_LIMIT,6000);
              System.out.println(4);
              ff=new File(SDCARD_ROOT_PATH + SAVE_PATH_IN_SDCARD,VIDEO_CAPTURE_NAME);
              System.out.println(5);
              cameraIntent.putExtra(MediaStore.EXTRA_OUTPUT, Uri.fromFile((ff)));
              System.out.println(6);
              startActivityForResult(cameraIntent,SELECT_PICTURE);
  </code></pre>