Hi
I have a problem with using evaluate in LS. The text below is in a text file(fileForSMS.txt) on my local hard drive.
I would like to extract the phone number(represented by lots of X)
Name: John Doe
Phone number: XXXXXXXXXXX Cellphone:YYYYYYYYYYYY
Adress:Blablabal
Here is the code in my agent. Somehow, the Text variable is not set by the Evaluate statement. The linein Variant is populated.
Dim filenum As Integer, filename As String, linein As String, Text As String
filename = "c:\fileForSMS.txt"
filenum% = Freefile()
Open filename For Input As filenum
Do Until Eof(filenum)
Line Input #filenum, linein
Dim tmpTekst As Variant
tmpText = Evaluate({@middle(linein;"phone number: ";11)})
Text = tmpTekst(0)
Loop
Any ideas?
Henrik