Skip to content Skip to sidebar Skip to footer

Unable To Instantiate Receiver No Empty Constructor

I want to perform operation when the user has internet activated but i get the following error : java.lang.InstantiationException: can't instantiate class com.project.proj.Network

Solution 1:

BroadcastReceiver can't have other constructor except default. Delete constructor you created.

Also, you don't need to pass context to BroadcastReceiver, in onReceive parameter is context.

Solution 2:

Post a Comment for "Unable To Instantiate Receiver No Empty Constructor"