Hi, I have created two AppMsg object like below,
public MyActivity extends Activity {
AppMsg noConnectionMsg, connectedMsg;
@Override
public void onCreate(Bundle bundle) {
noConnectionMsg = AppMsg.makeText(this,
getResources().getString(R.string.msgNoConnection),
AppMsg.STYLE_ALERT);
noConnectionMsg.setDuration(AppMsg.LENGTH_STICKY);
connectedMsg = AppMsg.makeText(this,
getResources().getString(R.string.msgConnected),
AppMsg.STYLE_INFO);
}
...
...
}
But when I run the application, notifications are successfully shown. After cancelling the AppMsgs, App is getting crashed with this Error:
Attempt to invoke virtual method 'boolean com.devspark.appmsg.AppMsg.isShowing()' on a null object reference.