Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Sub READ_JSON()
Dim arrFileLines() As Variant, I As Long, objFSO As Object, objFile As Object, L As Long
Dim NR As String
Dim VIA As String
Dim CITTA As String
Dim DISTRETTO As String
Dim REGIONE As String
Dim CAP As String
Dim ID As String
Dim COORD As String
Dim PARTS() As String
Dim LNG As String
Dim LAT As String, LINEA As String, RIGA As String
I = 0
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFile = objFSO.OpenTextFile("C:\Lavori_Vb6\STRADARIO\FILE\it_countrywide-addresses-country.TXT", 1)
Do Until objFile.AtEndOfStream
ReDim Preserve arrFileLines(I)
arrFileLines(I) = objFile.ReadLine
I = I + 1
If I Mod 50000 = 0 Then
' FOR TESTING
Exit Do
End If
Loop
objFile.Close
For L = LBound(arrFileLines) To UBound(arrFileLines)
'Debug.Print arrFileLines(L)
LINEA = Split(arrFileLines(L), ",")(0)
LINEA = Split(arrFileLines(L), ",")(1)
LINEA = Split(arrFileLines(L), ",")(2)
LINEA = Split(arrFileLines(L), ",")(3)
LINEA = Split(arrFileLines(L), ",")(4)
LINEA = Split(arrFileLines(L), ",")(5)
LINEA = Split(arrFileLines(L), ",")(6)
LINEA = Split(arrFileLines(L), ",")(7)
LINEA = Split(arrFileLines(L), ",")(8)
LINEA = Split(arrFileLines(L), ",")(9)
LINEA = Split(arrFileLines(L), ",")(10)
LINEA = Split(arrFileLines(L), ",")(11)
LINEA = Split(arrFileLines(L), ",")(12)
Next
Set objFSO = Nothing
Set objFile = Nothing
End Sub
Sub READ_JSON()
Dim strTextLine As String
Dim ary() As String
Open "C:\Lavori_Vb6\STRADARIO\FILE\it_countrywide-addresses-country.TXT" For Input As #1
Do While Not EOF(1)
Line Input #1, strTextLine
ary = Split(strTextLine, ",")
MsgBox Split(ary(2), ":")(0) & " - " & Split(ary(2), ":")(1)
MsgBox Split(ary(3), ":")(0) & " - " & Split(ary(3), ":")(1)
MsgBox Split(ary(5), ":")(0) & " - " & Split(ary(5), ":")(1)[green]
'Exit Do[/green]
Loop
Close #1
End Sub