any ideas why i getting "undeclared variable 'activity' is used before it was assigned any value"
B4X:
Sub Process_Globals
Dim soso As FTP_Auto
End Sub
Sub Service_Create
End Sub
Sub Service_Start (StartingIntent As Intent)
soso.Initialize(activity,Me,"ftp.DOMAIIN.com","USER","PASS",21,False,False)
soso.UpLoadFile(File.DirRootExternal,"/htdocs","test.txt")
soso.CloseNow
End Sub
Sub Service_Destroy
End Sub
Sub Process_Globals
Dim FTP As FTP
End Sub
Sub Globals
End Sub
Sub Activity_Create(FirstTime As Boolean)
If FirstTime Then
FTP.Initialize("ftp", ...)
FTP.UploadFile(File.DirRootExternal, ...)
End If
End Sub
Sub FTP_UploadProgress (ServerPath As String, TotalUploaded As Long, Total As Long)
Activity.Title = TotalUploaded
End Sub
Sub FTP_UploadCompleted (ServerPath As String, Success As Boolean)
Log("Completed: " & Success)
End Sub