14 de abril de 2012

Android Log

Error:
java.lang.NullPointerException: println needs a message

Solution:

public class MyLog {

public static void d(String tag, String msg) {
try {
android.util.Log.d((tag != null ? tag : "MyLog.d"), (msg != null ? msg : "NULL"));
} catch (Exception e) {
android.util.Log.e("MyLog.d ", "Error!");
}
}

}



Sem comentários:

LinkWithin

Related Posts with Thumbnails