Users Pricing

forum

Home Forums Stream not writing on a file – MindStick

Stream not writing on a file

Jayden Bell 1846 28 Jan 2014

Is there anything wrong with this piece of code ? It's opening the file , yet it doesn't write on it.

fl = new FileStream(path, FileMode.OpenOrCreate);
sw = new StreamWriter(fl);
sw.WriteLine("Hello ");

1 Answers

Markdown for AI

A clean, structured version of this page for AI assistants and LLMs.

Open .md