十年網(wǎng)站開(kāi)發(fā)經(jīng)驗(yàn) + 多家企業(yè)客戶 + 靠譜的建站團(tuán)隊(duì)
量身定制 + 運(yùn)營(yíng)維護(hù)+專業(yè)推廣+無(wú)憂售后,網(wǎng)站問(wèn)題一站解決
try{
創(chuàng)新互聯(lián)建站專注于浪卡子網(wǎng)站建設(shè)服務(wù)及定制,我們擁有豐富的企業(yè)做網(wǎng)站經(jīng)驗(yàn)。 熱誠(chéng)為您提供浪卡子營(yíng)銷型網(wǎng)站建設(shè),浪卡子網(wǎng)站制作、浪卡子網(wǎng)頁(yè)設(shè)計(jì)、浪卡子網(wǎng)站官網(wǎng)定制、微信平臺(tái)小程序開(kāi)發(fā)服務(wù),打造浪卡子網(wǎng)絡(luò)公司原創(chuàng)品牌,更為您提供浪卡子網(wǎng)站排名全網(wǎng)營(yíng)銷落地服務(wù)。
InputStream myInput = mcontext.getResources().openRawResource(R.raw.medicalspeciality);
InputStreamReader reader = new InputStreamReader(myInput);
BufferedReader breader = new BufferedReader(reader);
String str;
FileWriter myOutput = new FileWriter(outFileName, true);
while ((str = breader.readLine()) != null) {
System.out.println(i+++str);
}
// Close the streams
myOutput.flush();
myOutput.close();
myInput.close();
}catch (Exception e) {
// TODO: handle exception
e.getStackTrace();
}
ListBox1.Items(0).ToString() '第一行
mid(ListBox1.Items(0).ToString(),2,1) '第一行第二個(gè)字符
該控件只有1列
Private
Sub
Command1_Click()
Open
"f:\新建
文本文檔
.inf"
For
Input
As
#1
'(打開(kāi)文件,方式是讀取)
for
i=1
to
n
Line
Input
#1,
s
'(讀取第一行)
next
i
Text1.Text
=
s
Close
#1
'('關(guān)閉文件)
End
Sub
這里n取幾,text1里顯示的就是第幾行。
無(wú)法讀取指定的某一行,只能通過(guò)對(duì)整個(gè)文本框里的字符串,采用字符串函數(shù)等方法,分離獲得某一行的內(nèi)容。