Questions tagged [streamwriter]
StreamWriter is designed for character output in a particular encoding, whereas classes derived from Stream are designed for byte input and output.
streamwriter
336
questions with no upvoted or accepted answers
4
votes
0
answers
747
views
Write .wav file from soundcard output with node js
I'm a beginner with node js programming and I would like to build two different nodes that are able to capture microphone input and speaker output from a soundcard of a windows machine. The objective ...
4
votes
0
answers
283
views
Xamarin.Android and RecordAudio: how to combine file writing and other task
I develop a Xamarin.Android app where I need to record an audio file in a .wav and to display the related spectrogram in the same time.
I'm able to perform the 2 tasks separately but not to combine ...
4
votes
1
answer
758
views
Intermittent XmlSerializer (partially) null file
I'm using an XmlSerializer with a StreamWriter as follows:
...
string xmlFile = GetXMLLocation(objToSaveType);
XmlSerializer Serializer = new XmlSerializer(objToSaveType);
using (StreamWriter sw = ...
3
votes
0
answers
702
views
How to avoid StreamWriter from writing partial data to file
I'm using a StreamWriter to write data to a file. The data is a (potentially) long string that should be saved in full.
I've seen cases where the file is created, but its contents are not the entire ...
3
votes
0
answers
944
views
Add a column of Data to a CSV file to a specific column in the middle
I'm using C# and Visual Studio Express 2010. I have a column of a datatable that I want to insert into a CSV file that already has some data. I want to send the data to the fifth column specifically. ...
3
votes
0
answers
900
views
jax-ws endpoint gets blocked writting on socket since Java 8 upgrade
We use JAX-WS implementation with JAXB for webservices, we have recently upgraded to jdk 8, since then we are having an issue when our endpoint is sending the responses. After digging into it, I ...
2
votes
0
answers
134
views
System.NotSupportedException when reading from StreamReader of the standard output of a DOSBox process in a C# Console Application
I am running into an issue reading the output/input of a DOSBox Process started by my C# console application. DOSBox has an encoding for code page 437, but setting up my StreamReader with that ...
2
votes
0
answers
141
views
Why Writing Number in Text File Takes a Lot of Time?
I have written a program that take 0.1092 seconds to generate a number but 787.26012 seconds =13 minute to write that number (3.81 MB) in/on a text file, which is quite surprising, can anyone explain ...
2
votes
0
answers
411
views
Random occurence of System.ArgumentNullException in Windows Service
I have been facing this weird issue with my WCF service which is already Deployed.
It has been set to automatic restart in case of errors.
I have been observing my service is getting stopped randomly....
2
votes
0
answers
150
views
One process writes to file, I open it manualy (readonly) , I got exception "The process cannot access the file ..."?
I'm trying to allow just one process be able to write to a file and other processes could only read it , so I tried to open the file by:
sw = new StreamWriter(File.Open(filepath, FileMode.Create, ...
2
votes
1
answer
224
views
Delay in declaration of StreamWriter variable
In my C# application I have a while loop that gathers a string from a Redis message queue and sends it to a listening server.
At every cicle the connection is opened with an HttpWebRequest Post method ...
2
votes
0
answers
624
views
Difference between NetworkStream.Write and StreamWriter.Write
Hello it would be very nice if someone could tell me the difference between the NetworkStream.Write and the StreamWriter.Write. I'm using a TcpClient and don't know which should be better to use for ...
2
votes
2
answers
2k
views
How to read a line and write to that line, of a text file?
I'm use MS-Visual Studio 2015, develop a Winforms application in C#.
What I'm trying to reach is a reader&writer which opens a CSV file with UTF-8 coding, and reads line for line. My program ...
2
votes
0
answers
47
views
Need assistance with writing to a CSV file and saving entries
I am creating a student test score application which shows student averages, class averages (I haven't done this part yet) and can search for a particular student which shows up in the text boxes.
...
2
votes
0
answers
656
views
C# Program Reading, Writing to Console, but Not to File
I am trying to alphabetize all the words in a text file using C#. I am able to read the file and fill the list properly. I am then able to iterate through the list and print to the console. However, ...