开发工具:C++Builder 2010
功能:读取TXT文本 分割到 超级列表框
Delphi通用!!!
void __fastcall TForm1::读取坐标数据()
{
lv1->Clear();
TStringList * mList = new TStringList;
TStringList * ts = new TStringList;
TListItem *lvItem;
ts->Clear();
mList->Clear();
ts->LoadFromFile("Address.txt");
mList->Delimiter ='|';
for (short i =0;i<ts->Count-1;i++ )
{
mList->DelimitedText = ts->Strings[i];
lvItem = lv1->Items->Add();
lvItem->Caption=IntToStr(i+1);
lvItem->SubItems->Add(mList->Strings[0]);
lvItem->SubItems->Add(mList->Strings[1]);
lvItem->SubItems->Add(m