
[已解決]批處理怎樣查找文本不定行指定內容并輸出要查找的文本內容片斷:Basic:User access index : 854State : UsedUser name : zhangsanUser access status1 : OKUser access status2 : OKUser access PeVlan/CeVlan : 2112/1120User-Group: - AAA:Action flag : IdleAuthen state: AuthedAuthor state: IdleBasic:User access index : 231State : UsedUser name : huangliUser access status1 : OKUser access status2 : OKUser access PeVlan/CeVlan : 2372/6490User-Group: - AAA:Action flag : IdleAuthen state: AuthedAuthor state: IdleBasic:User access index : 251State : UsedUser name : liliangUser access status1 : OKUser access status2 : OKUser access PeVlan/CeVlan : 3111/2643User-Group: - AAA:Action flag : IdleAuthen state: AuthedAuthor state: IdleBasic:User access index : 104State : UsedUser name : sunqianUser access status1 : OKUser access status2 : OKUser access PeVlan/CeVlan : 1128/3243User-Group: - AAA:Action flag : IdleAuthen state: AuthedAuthor state: Idle想要得到的結果(輸出到csv表格文件):zhangsan,2112/1120huangli,2372/6490liliang,3111/2643sunqian,1128/3243即:查找User name和User access PeVlan/CeVlan冒號后面的內容,成對輸出(Basic和AAA塊成對出現屬于一個文本域)小弟只能單行處理,資歷較淺,無法成對輸出,幫小弟一把,謝啦老大

