How can i solve the syntax error problem of variable declarator id issue. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How can i solve the syntax error problem of variable declarator id issue.

anytime I run the code, its tells me to insert variable declaratorId to complete formal parameter list.

16th May 2020, 7:14 AM
Dukori Francis
Dukori Francis - avatar
8 Answers
+ 1
ok, I will do that, thanks
16th May 2020, 7:23 AM
Dukori Francis
Dukori Francis - avatar
+ 1
ok, thanks
16th May 2020, 7:57 AM
Dukori Francis
Dukori Francis - avatar
0
If you provide the code here, we can help you... Otherwise, the answer we provided may not match with your question
16th May 2020, 7:22 AM
sarada lakshmi
sarada lakshmi - avatar
0
here is the codes: import android.app.Activity; import android.os.Bundle; public class MainActivity extends Activity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); buttonshow = findViewById(R.id.bt_show); adView1 = findViewById(R.id.ad_view1); adView2 = findViewById(R.id.ad_view2); AdRequest adRequest = new AdRequest.Builder().build(); adView1.loadAd(adRequest); adView2.loadAd(adRequest); interstitialAd = new interstitial( context, this); interstitialAd.setAdUnit("ca-app-pub-6922536427496192/1656265555"); interstitialAd.loadAd(new AdRequest.Builder().build()); "" buttonshow.setOnClickListener(new View.OnClickListener(){ @Override public void OnClick(view){ interstitialAd.show(); } }); } }
16th May 2020, 7:29 AM
Dukori Francis
Dukori Francis - avatar
0
I'm not familiar with those packages which you have imported... But, the thing is I didn't found any main() in that program
16th May 2020, 7:36 AM
sarada lakshmi
sarada lakshmi - avatar
0
OK
16th May 2020, 7:44 AM
Dukori Francis
Dukori Francis - avatar
0
so where do I need to insert main?
16th May 2020, 7:50 AM
Dukori Francis
Dukori Francis - avatar
0
Try to write in another class
16th May 2020, 7:55 AM
sarada lakshmi
sarada lakshmi - avatar