NMFTP是否無法取得中文檔名列表? |
缺席
|
chrislove87
一般會員 發表:11 回覆:14 積分:5 註冊:2007-05-09 發送簡訊給我 |
小弟用NMFTP元件稍做了一個小型的FTP程式
若目錄下檔案皆為英文的話,就都會正常執行, 若為中文就會跳出錯誤,錯誤是寫 "中文XX" 並非integer型態,然後"中文XX"出現在修改時間這一格, 不知道問題到底是出在哪... 請各位高手幫忙解答一下...3Q [code cpp] int i; switch(Trans_Type){ case cmdList: for(i=0;i<=(StringGrid1->ColCount-1);i ) StringGrid1->Cols[i]->Clear(); StringGrid1->RowCount = NMFTP1->FTPDirectoryList->name->Count 1; StringGrid1->ColCount=5; StringGrid1->Cells[0][0]=""; StringGrid1->Cells[1][0]="檔名"; StringGrid1->Cells[2][0]="大小"; StringGrid1->Cells[3][0]="修改日期"; StringGrid1->Cells[4][0]="屬性"; for(i=0;i<=(NMFTP1->FTPDirectoryList->name->Count-1);i ){ if(StrToInt(NMFTP1->FTPDirectoryList->Size->Strings[i])<=512) StringGrid1->Cells[0][i 1]="資料夾"; else StringGrid1->Cells[0][i 1]="檔案"; //若檔案大小=<512則為資料夾 StringGrid1->Cells[1][i 1]=NMFTP1->FTPDirectoryList->name->Strings[i]; StringGrid1->Cells[2][i 1]=NMFTP1->FTPDirectoryList->Size->Strings[i]; StringGrid1->Cells[3][i 1]=NMFTP1->FTPDirectoryList->ModifDate->Strings[i]; StringGrid1->Cells[4][i 1]=NMFTP1->FTPDirectoryList->Attribute->Strings[i]; } break; } [/code] |
chrislove87
一般會員 發表:11 回覆:14 積分:5 註冊:2007-05-09 發送簡訊給我 |
本站聲明 |
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。 2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。 3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇! |