java - The method is undefined for the type in Eclipse -
method undefined type in eclipse. can't seem solve it. error in lines: msg.settimestamp( system.currenttimemillis() ); , msg.setbody("this test sms message");
package com.example.smsnotification; import android.app.activity; import android.app.alertdialog; import android.app.alertdialog.builder; import android.content.dialoginterface; import android.content.intent; import android.os.bundle; public class popsmsactivity extends activity{ @override public void oncreate(bundle savedinstancestate) { super.oncreate(savedinstancestate); //retrieve serializable sms message object key "msg" used pass intent in = this.getintent(); popmessage msg = (popmessage) in.getserializableextra("msg"); //case launch app test ui eg: no incoming sms if(msg==null){ msg = new popmessage(); con.setphone("0123456789"); msg.settimestamp( system.currenttimemillis() ); msg.setbody("this test sms message"); } showdialog(msg); }
remove code , write eclipse. worked me....you can try copy , paste after writing signature of function/class.
Comments
Post a Comment