Reading text file containing data and output data in excel

Closed
idrees_azad Posts 1 Registration date Saturday July 22, 2017 Status Member Last seen July 22, 2017 - Jul 22, 2017 at 04:33 AM
Hi,
I have a text file containing system counter data and is separated by semi-colon ";" as below:
Group id; Counter id; Instance id; Timestamp; Counter Value
BSG; NALLBSGACR; 1 ; 2017-07-21 15:30:00; 0
BSG; NALLBSGAOCC; 2 ; 2017-07-21 15:30:00; 0
ASYNCR; NASYNCRCFU; 1 ; 2017-07-21 15:30:00; 0
ASYNCR; NASYNCRDCF; 2 ; 2017-07-21 15:30:00; 0
AUCSUBS; NGSUBSCNT; 1 ; 2017-07-21 15:30:00; 262
AUCSUBS; NSUBSCNT; 2 ; 2017-07-21 15:30:00; 262

I want to parse the data based on group id and output the data in different workbooks in one excel sheet. For ex., workbook name BSG contains data as below:
Counter id; Instance id; Timestamp ; Counter Value
NALLBSGACR; 1 ; 2017-07-21 15:30:00; 0
NALLBSGAOCC; 2 ; 2017-07-21 15:30:00; 0

and similarly in another workbook named ASYNCR contains data like below:
Counter id; Instance id ; Timestamp ; Counter Value
NASYNCRCFU; 1 ; 2017-07-21 15:30:00; 0
NASYNCRDCF; 2 ; 2017-07-21 15:30:00; 0

My text file contains many Group Ids and accordingly so many workbooks in one excel is desired. Finally I dont want to use the code everytime I need to parse data but a macro saved in one excel executed and takes the text file as input and gives the output in different excel.

I know it is not that easy for me, but for coders here in the forum its a job of few minutes :)


Many Thanks in advance.