Case DialogResponse.POSITIVE
Activity.RemoveAllViews
Activity.LoadLayout("Main")
http.Initialize("http", Me)
http.Download("http://blank.com/blank.apk")
End Select
End If
End Sub
Sub JobDone (Job As HttpJob)
If Job.Success == True Then
Dim out As OutputStream
out = File.OpenOutput(File.DirDefaultExternal,"blank.apk",False )
'File.Copy2(http.GetInputStream, out)
File.Copy2(Job.GetInputStream, out)
http.Release
out.Close
ToastMessageShow("Downloaded!", False)
Else
http.Release
ToastMessageShow("Download failed.", False)
End If
End Sub