Sub Globals
Private btn As Button
Private edt As EditText
Private lbl As Label
Private mp As Map
End Sub
Sub Activity_Create(FirstTime As Boolean)
mp.Initialize
mp.Put("house", 50)
mp.Put("car", 100)
mp.Put("games", 25) 'then you can store the map into a file and retrieve the map when you want to
edt.Initialize("edt")
Activity.AddView(edt, 0,0, 200dip, 75dip)
edt.Hint="Enter object here"
lbl.Initialize("lbl")
Activity.AddView(lbl,300dip,0,150dip,75dip) 'via code, but you can do it via designer
lbl.Color=Colors.Blue
btn.Initialize("btn")
Activity.AddView(btn,200dip,300dip, 150dip, 100dip)
btn.Text="Click me"
btn.Color=Colors.Red
End Sub
Sub btn_Click
lbl.Text="$" & mp.Get(edt.Text)
End Sub]/code]