Moon_sky_qq
2022-06-22 08:05
采纳率: 0%
浏览 1.6k

Android APP打包后程序运行报错,求解,/AndroidRuntime: FATAL EXCEPTION: main。

Android APP打包后程序运行报错,求大神,/AndroidRuntime: FATAL EXCEPTION: main。

2022-06-21 16:33:39.826 8277-8277/com.sqsxiu.sampling_record E/AndroidRuntime: FATAL EXCEPTION: main
    Process: com.sqsxiu.sampling_record, PID: 8277
    java.lang.RuntimeException: Unable to start activity ComponentInfo{com.sqsxiu.sampling_record/com.sqsxiu.sampling_record.activity.RaskListDetailsActivity}: java.lang.NullPointerException
        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2944)
        at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3079)
        at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:78)
        at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
        at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1836)
        at android.os.Handler.dispatchMessage(Handler.java:106)
        at android.os.Looper.loop(Looper.java:193)
        at android.app.ActivityThread.main(ActivityThread.java:6702)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:911)
     Caused by: java.lang.NullPointerException
        at java.io.Writer.<init>(Writer.java:88)
        at java.io.OutputStreamWriter.<init>(OutputStreamWriter.java:97)
        at com.example.print_sdk.PrintUtil.<init>(PrintUtil.java:56)
        at com.sqsxiu.sampling_record.activity.RaskListDetailsActivity.initPos(RaskListDetailsActivity.java:444)
        at com.sqsxiu.sampling_record.activity.RaskListDetailsActivity.onCreate(RaskListDetailsActivity.java:226)
        at android.app.Activity.performCreate(Activity.java:7136)
        at android.app.Activity.performCreate(Activity.java:7127)
        at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1271)
        at android.app.ActivityThread

  • 写回答
  • 好问题 提建议
  • 追加酬金
  • 关注问题
  • 邀请回答

23条回答 默认 最新

相关推荐 更多相似问题