On Fri, 10 Sep 2021 09:46:11 +0200, Sven Barth via fpc-pascal
<fpc-pascal@lists.freepascal.org> wrote:

>You can use the ipconfig command and parse its output (especially ipconfig
>/all).

I also figured that to be the case, so I will run TProcess with Ipconfig /all
and then parse the result line by line.

It looks like there is a simple system to it:

Adapter headings start at pos 1 on a line.
   Data within the adapter start on pos 4 on each line

And the adapter name starts directly after the word "adapter " on the heading
line.

Data for this adapter follow until the next adapter starts.

Should be easy enough to parse out.

Thanks!

-- 
Bo Berglund
Developer in Sweden

_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to