Hi ,

I want to make a program who read a word from a textfile .

More accurate,

In The text file I have the next text:

Version="1.0"
Adress="http://"
StartFile="/"

and my program I want to read what is

From Version , to read 1.0
From Adress to read http:// etc.

Sorry for my bad english .

If you do a Split(line,"=") on each line you will get an array where element 0 has everything to the left of "=" and element 1 gets everything to the right. In actual code it looks like

For Each line As String In System.IO.File.ReadAllLines("D:\test.txt")
    Dim fields() As String = line.Split("=")
    If UBound(fields) > 0 Then
        fields(1) = fields(1).Replace("""", "")
        MsgBox(fields(0) & " has the value " & fields(1))
    End If
Next

Note that I remove the quotation marks in fields(1).

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.