Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
TXT file doesn´t close
Message
From
20/10/2015 15:41:35
 
 
To
20/10/2015 11:31:34
General information
Forum:
ASP.NET
Category:
Other
Environment versions
Environment:
VB.NET 1.1
OS:
Windows 8.1
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Desktop
Miscellaneous
Thread ID:
01626227
Message ID:
01626239
Views:
50
Hello Michel;

Thanks a lot for your reply.

I´m a little confuse.

Could you give me hand to apply your recomendation to my script?

My script
Using sr As StreamReader = txtfile.OpenText
File.AppendAllText(Path.Combine(topDir.FullName, curFilename), sr.ReadToEnd, Encoding.Default)
End Using

Your script
Using loFileStream As System.IO.FileStream = New FileStream(lcFile, FileMode.Create)
loStreamWriter = New StreamWriter(loFileStream, cEncoding)
loStreamWriter.Write(cString)
loStreamWriter.Close()
End Using

Thanks a lot
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform