Im reading from an XML file which has a record called 'position' and has an input like
1
2
3
4
5
6
7
W
The 'W' means withdrawn but when the file is read it throws an error because i think its reading it as an integer instead of string, i'm getting...
How can i make sure ResultElement.GetFirstChildElementByName("position").value is read as a string value?????
1
2
3
4
5
6
7
W
The 'W' means withdrawn but when the file is read it throws an error because i think its reading it as an integer instead of string, i'm getting...
An error has occured in sub:main_buildlistview(java line:305) java.lang.RuntimeException: Object should first be initialized (XOMElement)
How can i make sure ResultElement.GetFirstChildElementByName("position").value is read as a string value?????
B4X:
Sub BuildListView
Dim i As Int
Dim ListTitle As String
Dim ResultElement As XOMElement
Dim yearString As String
Dim competitionString As String
Dim sectionString As String
yearString = "2013"
competitionString = "Butlins Mineworkers"
sectionString = "Third"
For i=0 To ResultElements.Size-1
ResultElement=ResultElements.GetElement(i)
If ResultElement.GetFirstChildElementByName("compName").value = competitionString _
AND ResultElement.GetFirstChildElementByName("year").value = yearString _
AND ResultElement.GetFirstChildElementByName("section").value = sectionString Then
Table1.AddRow(Array As String(ResultElement.GetFirstChildElementByName("position").value, _
ResultElement.GetFirstChildElementByName("bandName").value, _
ResultElement.GetFirstChildElementByName("conductor").value))
End If
Next
End Sub