我在java中有一个带有蓝牙连接的android应用程序,当我更改布局方向(我创建了layout-land文件夹)时,布局会正确更改,但是我拥有的信息丢失了,收到的所有消息都消失了,什么时候我尝试发送一条消息它崩溃了,它向我显示了这个异常,就像连接丢失但它仍在运行:
D/AndroidRuntime(29591): Shutting down VM
08-01 10:13:04.499: W/dalvikvm(29591): threadid=1: thread exiting with uncaught exception (group=0x2aac8578)
08-01 10:13:04.519: E/AndroidRuntime(29591): FATAL EXCEPTION: main
08-01 10:13:04.519: E/AndroidRuntime(29591): java.lang.IllegalStateException: Could not execute method of the activity
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.view.View$1.onClick(View.java:2168)
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.view.View.performClick(View.java:2552)
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.widget.CompoundButton.performClick(CompoundButton.java:103)
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.view.View$PerformClick.run(View.java:9229)
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.os.Handler.handleCallback(Handler.java:587)
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.os.Handler.dispatchMessage(Handler.java:92)
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.os.Looper.loop(Looper.java:138)
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.app.ActivityThread.main(ActivityThread.java:3701)
08-01 10:13:04.519: E/AndroidRuntime(29591): at java.lang.reflect.Method.invokeNative(Native Method)
08-01 10:13:04.519: E/AndroidRuntime(29591): at java.lang.reflect.Method.invoke(Method.java:507)
08-01 10:13:04.519: E/AndroidRuntime(29591): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:878)
08-01 10:13:04.519: E/AndroidRuntime(29591): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636)
08-01 10:13:04.519: E/AndroidRuntime(29591): at dalvik.system.NativeStart.main(Native Method)
08-01 10:13:04.519: E/AndroidRuntime(29591): Caused by: java.lang.reflect.InvocationTargetException
08-01 10:13:04.519: E/AndroidRuntime(29591): at java.lang.reflect.Method.invokeNative(Native Method)
08-01 10:13:04.519: E/AndroidRuntime(29591): at java.lang.reflect.Method.invoke(Method.java:507)
08-01 10:13:04.519: E/AndroidRuntime(29591): at android.view.View$1.onClick(View.java:2163)
08-01 10:13:04.519: E/AndroidRuntime(29591): ... 12 more
08-01 10:13:04.519: E/AndroidRuntime(29591): Caused by: java.lang.NullPointerException
08-01 10:13:04.519: E/AndroidRuntime(29591): at com.example.bluetooth.cochee.BluetoothConexion.escribir(BluetoothConexion.java:350)
08-01 10:13:04.519: E/AndroidRuntime(29591): at com.example.bluetooth.cochee.AndroidTabsActivity.Comprobar5(AndroidTabsActivity.java:554)
08-01 10:13:04.519: E/AndroidRuntime(29591): ... 15 more
08-01 10:13:07.429: I/Process(29591): Sending signal. PID: 29591 SIG: 9
08-01 10:13:09.849: W/KeyCharacterMap(29760): Can't open keycharmap file
08-01 10:13:09.849: W/KeyCharacterMap(29760): Error loading keycharmap file '/system/usr/keychars/clearpad.kcm.bin'. hw.keyboards.65541.devname='clearpad'
08-01 10:13:09.849: W/KeyCharacterMap(29760): Using default keymap: /system/usr/keychars/qwerty.kcm.bin