Finding a specific range of character in file

hi,

I want to store from 102 character to 128 character to a variable of header record which can be identified as 'HDR' which is the first 3 characters in the same line of a same.txt file.
Please advise.

Thanks

Please clarify your requirements, give us an exemple of input you have and result you expect

I was able to get it done..thanks..

Because a forum is not only for asking but also for sharing, that could be nice for the others if you would post how you solved you problem, so anyone of the community encountering the same issue could take advantage of it.

head -1 $filename|cut -c102-128