Are tyheses obsolete methods?

Working with RB2012 R2

I have the following code section:

    //open for writing, if file dooes not exist then create it
    if TargetFile.Exists = false then
      tos = TargetFile.CreateTextFile
    end if

tos is declared elsewhere as TextOutputStream

This code was written several years ago (RB2008 or so).
It compiles and works OK however there is something strange.
The methods CreateTextFile and AppendToTextFile do not appear when auto completing and also I can not find any mention to them in the language reference.
Are they obsolete (but apparently still supported)?
If they are obsolete, what is their replacement?

They are deprecated / obsolete. They are replaced by the corresponding TextOutputStream methods

tos = TextOutputStream.Create(TargetFile)


tos = TextOutputStream.Append(TargetFile)

Thanks - will update my code

Don’t forget that the new methods throw Exceptions when an error occurs! Any error handling you have will need to be converted to try-catch!