Iska,
PHP код:

08/02/2013-06h56m52s187ms | --> | 0xcac | +bnr_QueryCashUnit () : transpC=0
BU id=43061200124 count=0 status=6031 lock=0 threshold:mode/e-l-h-f/status=1/0-0-0-15/8
6 0- - id=43061200124 kind=6019 type=6029 status=6031 initialCount=0 count=0
CB id= count=171 status=6031 lock=0 threshold:mode/e-l-h-f/status=0/0-0-0-600/0
12 0- - id= kind=6017 type=6021 status=6031 init-/dep-/retr-/empt-/forg-/disap-/count = 0/17/0/0/0/13/17
13 5000-RUB-AA id= kind=6017 type=6023 status=6031 init-/dep-/retr-/empt-/forg-/disap-/count = 0/2095/0/0/0/0/0
14 500000-RUB-AA id= kind=6017 type=6023 status=6031 init-/dep-/retr-/empt-/forg-/disap-/count = 0/1083/0/0/0/0/3
15 1000-RUB-AA id= kind=6017 type=6023 status=6031 init-/dep-/retr-/empt-/forg-/disap-/count = 0/1639/0/0/0/0/18
16 10000-RUB-AA id= kind=6017 type=6023 status=6031 init-/dep-/retr-/empt-/forg-/disap-/count = 0/4235/0/0/0/1/43
17 100000-RUB-AA id= kind=6017 type=6023 status=6031 init-/dep-/retr-/empt-/forg-/disap-/count = 0/13026/0/0/0/0/58
18 50000-RUB-AA id= kind=6017 type=6023 status=6031 init-/dep-/retr-/empt-/forg-/disap-/count = 0/6167/0/0/0/0/32
LO1 id=41060800075 count=113 status=6031 lock=0 threshold:mode/e-l-h-f/status=0/0-0-0-200/0
5 5000-RUB-AA id=41060800075 kind=6019 type=6029 status=6031 initialCount=0 count=0
11 5000-RUB-AA id=41060800075 kind=6016 type=6023 status=6031 init-/disp-/rej-/count = 0/33/0/113
RE3 id=41061000138 count=23 status=6031 lock=0 threshold:mode/e-l-h-f/status=1/0-15-100-30/0
1 5000-RUB-AA id=41061000138 kind=6019 type=6029 status=6031 initialCount=0 count=0
7 5000-RUB-AA id=41061000138 kind=6018 type=6023 status=6031 initialCount=0 count=23
RE4 id=41061000138 count=45 status=6031 lock=0 threshold:mode/e-l-h-f/status=1/0-0-100-55/0
2 10000-RUB-AA id=41061000138 kind=6019 type=6029 status=6031 initialCount=0 count=0
8 10000-RUB-AA id=41061000138 kind=6018 type=6023 status=6031 initialCount=0 count=45
RE5 id=41061000139 count=30 status=6031 lock=0 threshold:mode/e-l-h-f/status=1/0-0-100-30/1
3 100000-RUB-AA id=41061000139 kind=6019 type=6029 status=6031 initialCount=0 count=0
9 100000-RUB-AA id=41061000139 kind=6018 type=6023 status=6031 initialCount=0 count=30
RE6 id=41061000139 count=55 status=6031 lock=0 threshold:mode/e-l-h-f/status=1/0-0-100-55/1
4 50000-RUB-AA id=41061000139 kind=6019 type=6029 status=6031 initialCount=0 count=0
10 50000-RUB-AA id=41061000139 kind=6018 type=6023 status=6031 initialCount=0 count=55
Вот такие вот сообщения периодически пишут в текстовый файл. Глобально задача в том чтобы находить самый низ файла, там находить каждый ID из четырёх RE (3,4,5,6), оттуда брать значение второй строчки count=* После всего этого надо собранные значения с указанием даты и времени выписывать в какой-нить свой лог. Значения count всегда цифровые и не превышают 300.
Скрипт планирую положить в качестве задачи и выполнять каждые минут 15. В итоге всё это надо будет экспортировать в 1С, но это уже проблема других людей.