# 如何解析用点和等分隔的数据然后添加到listview(How to parsing data from delimited with dot and equal then add to listview)

``` 我有一些如下数据
```1000.2000=2A.3000.4000=1.5000=2,5B
```
需要解析数据并添加到listview。 我已经用数组制作代码但仍然无法工作，我需要解决方案。
```Dim str As String = "1000.2000=2A.3000.4000=1.5000=2,5B"
Dim tabLine() As String
tabLine = str.Split("."c)
For k As Integer = 0 To tabLine.Length - 1
Dim listitem As ListViewItem
Dim sep As Char() = New Char(0) {}
sep(0) = "="c
For Each s As String In tabLine(k).Split(sep, 2)
Next
Next
```
上面的代码告诉我这个结果
```-----------------
1000 |      |
2000 |   2A |
3000 |      |
4000 |   1  |
5000 | 2.5B |
```
我想要如下结果
```-----------------
1000 |   2 | A
2000 |   2 | A
3000 |   1 |
4000 |   1 |
5000 | 2.5 | B
```I have some data like below
```1000.2000=2A.3000.4000=1.5000=2,5B
```
need to parse the data and add to listview. I already make the code with array but still not work and i need the solution.
```Dim str As String = "1000.2000=2A.3000.4000=1.5000=2,5B"
Dim tabLine() As String
tabLine = str.Split("."c)
For k As Integer = 0 To tabLine.Length - 1
Dim listitem As ListViewItem
Dim sep As Char() = New Char(0) {}
sep(0) = "="c
For Each s As String In tabLine(k).Split(sep, 2)
Next
Next
```
the above code show me this result
```-----------------
1000 |      |
2000 |   2A |
3000 |      |
4000 |   1  |
5000 | 2.5B |
```
I want the result like below
```-----------------
1000 |   2 | A
2000 |   2 | A
3000 |   1 |
4000 |   1 |
5000 | 2.5 | B
```原文：https://stackoverflow.com/questions/34896032```