if (Newparticipant != null && Newparticipant.length() > 0) {
BA.Log("------New User-----");
rtcEvents.onNewParticipant(Newparticipant.toString());
}
// then i call it in b4a event like following
public void onNewParticipant(String participantJson) {
B4a.raiseEventFromDifferentThread(Globalunit.this,null,0,eventName+"_onnewparticipant", false, new Object[] {participantJson});
}