i am creating a simple splash screen , but i am unable to understand that why R.java file is getting deleted automatically every time i create a new project. only error i am getting is for R.java file, which is "R cannot be resolved to a variable". i have already tried importing R into my project using Import.android.R, but error is still there. please anybody with solution. thanks
the part of the code in which error is as follows:
package com.example.whereareyou3;
//import android.R;
import android.R;
import android.os.Bundle;
import android.os.Handler;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;
import android.widget.ProgressBar;
public class MainActivity extends Activity {
    Handler h1 = new Handler();
    private ProgressBar mProgress;
    long ms,splashTime=7000;
    boolean splashActive = true;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        requestWindowFeature(Window.FEATURE_NO_TITLE);
        getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN);
        setContentView(R.layout.activity_main);
 
     
     
    