I am posting this because I already wasted one day searching and programming for what really should be easy to set up even in Metro.
I am looking for an example of a C # StreamSocket that can connect to a socket, read data from a socket (I don’t know exactly when the data will arrive, so I always want to listen to new data) and write data to it at arbitrary times. It was an easy task to execute in every language programming environment (including .NET), but I cannot do it in Metro without getting exceptions ( ObjectDisposedExceptions when trying to write while waiting for incoming data).
These Metro examples are too simple because they know exactly when to poll the data. This simple task should really be possible!
source share