FUNZIONA
Sub Process_Globals
End Sub
Sub Globals
Dim AdoConn As AdoConnection
Dim AdoRec As AdoRecordset
Dim listview1 As ListView
End Sub
Sub OpenDB
AdoConn.ConnectionString("db4free.net","3306","UTF-8","dbphp","frac3sc0","123456")
AdoConn.ConnectionTimeout=1
AdoConn.LoginTimeout=1
AdoConn.SocketTimeout=1
AdoConn.InitializeEvent
AdoConn.Open
AdoRec.InitializeEvent
AdoRec.Connection=AdoConn
AdoRec.SqlStatement="select * from tblDatiAccesso"
AdoRec.Open
End Sub
Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("Main")
End Sub
Sub ElencoClienti
If AdoRec.RecordCount>0 Then
listview1.Clear
Do While Not(AdoRec.EOF)
listview1.AddSingleLine (AdoRec.Field("username"))
AdoRec.MoveNext
Loop
End If
End Sub
Sub Button1_Click
OpenDB
ElencoClienti
End Sub
MANIFEST
'This code will be applied to the manifest file during compilation.
'You do not need to modify it in most cases.
'See this link for for more information:
http://www.b4x.com/forum/showthread.php?p=78136
AddManifestText(
<uses-sdk android:minSdkVersion="4"/>
<supports-screens android:largeScreens="true"
android:normalScreens="true"
android:smallScreens="true"
android:anyDensity="true"/>)
SetApplicationAttribute(android:icon, "@drawable/icon")
SetApplicationAttribute(android:label, "$LABEL$")
'End of default text.
GRAZIEEEEEEEEEEEEEEEE