Quantcast
Channel: VBForums
Viewing all articles
Browse latest Browse all 15429

VS 2019 [Vb.net] Split text from txt file and get second value

$
0
0
Previously with .net visual studio 2010 I made this code below a script language to play with her idea was as follows

read from the txt file the highlighted word in the case below echo and cut the word echo and get the next ones and put it in the variable RUN

so print, but for some reason my code does not work in .net core is there any specific reason?

HTML Code:

For Each line As String In System.IO.File.ReadLines(sfilename)
            ' Display the line.
            Dim execommand = line.ToString
            Dim run As String
            If execommand = "echo" Then
                run = execommand.Split.ToString(1)
                MsgBox(run)
            End If
        Next


Viewing all articles
Browse latest Browse all 15429

Latest Images

Trending Articles



Latest Images

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