Android Question add date and time to label

Status
Not open for further replies.

maryam2027

New Member
hi i want to show date and time in label. my code is :
Private Label1 As Label
Private Label2 As Label
End Sub

Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("main")
DateTime.DateFormat="dd MMM yyyy"
Label1.Text=DateTime.Date(DateTime.Now)
DateTime.TimeFormat="hh:mm"
Label2.Text=DateTime.Time(DateTime.Now)
when i compile it there is no errors but when i want to run it on my phone the app was stopped working
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…