Hey all,
Im still new to this whole app creation world, so thought i might be able tog et some help as i cant find and tutorials thus far on my specific problem.
What i am trying to do is create a list, that when the list item is pressed it opens a new layout that displays a picture, the name of the Event (same as list item), date, time, location & Info.
I have created simliar sorts of programs, although creation in B4a is a little different which is making it a little harder.
My thoughts would be to create a database table firstly with all of those headings as column name
Sub CreateTable
SQL1.ExecNonQuery("DROP TABLE IF EXISTS EventsTable")
SQL1.ExecNonQuery("CREATE TABLE table1 (Date DATE , Time TIME, Name TEXT, Location Text, Co-Ords Text, Information TEXT, Picture Text)")
End Sub
Then from that i would populate the table
Sub FillTable
SQL1.ExecNonQuery("INSERT INTO EventsTable VALUES(28/11/2012, 08:40, 'Welcoming', 'Main Grounds', 'XX XX', ' event where everyone is welcomed to rottenest and info is given out to all, Welcoming.jpg)")
End Sub
Then once the database is created i would create the designer with a ListView named ListV which i would populate with the names of the instances that have been inserted into the database
Sub Populating_List
Try
For i = 1 To SQL1.ExecQuerySingleResult("SELECT count(*) FROM EventsTable")
ListV.AddSingleLine(SQL1.ExecQuerySingleResult("SELECT Name FROM EventsTable"))
Next
SQL1.TransactionSuccessful
Catch
Log(LastException.Message)
End Try
End Sub
well thats the plan anywayz, although i have run into a few syntax errors as i am still not use to system as of yet, so would anyone be able to give me a hand (mainly in the populating the listView) or if you have a better suggestion as how to tackle the problem feel free to add
kindest regards
luke