Quantcast
Channel: Windows PowerShell Forum
Viewing all articles
Browse latest Browse all 2562

how to deal with specific formatted content ?

$
0
0

Hello everyone,

I am trying to use a text file that comes from a router.

it contains information that is presented this way:

a lot of lines that won't be used by the script

!
!
ephone
number
label
description
name
morestuff
!
!
ephone

etc...

this is not Xml and some lines do not appear for each entry.

how would you deal with those types of files ?

Is is possible to filter out all lines before a  specific line (that contains the first value we are interested in)?

how would you keep the blocks between the !! signs together ?

Thanks in advance for you suggestions

Bruno


bruno


Viewing all articles
Browse latest Browse all 2562

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>