This project has moved and is read-only. For the latest updates, please go here.

User Streaming in Windows Phone

Sep 10, 2012 at 3:33 PM

int count = 0;
                var twitterCtx = new TwitterContext(auth);
                StreamContent streamContent = null;

                (from strm in twitterCtx.UserStream
                 where strm.Type == UserStreamType.User
                 select strm)
                    .StreamingCallback(strm =>
                        if (strm.Status == TwitterErrorStatus.RequestProcessingException)
                            WebException wex = strm.Error as WebException;
                            if (wex != null && wex.Status == WebExceptionStatus.ConnectFailure)
                                //Console.WriteLine(wex.Message + " You might want to reconnect.");

                        else if (strm.Status == TwitterErrorStatus.TwitterApiError)

                        streamContent = strm;

                        //Console.WriteLine(strm.Content + "\n");

                        if (count++ >= 5)

Hi Joe,

I am using above code for streaming User content on Windows Phone but stream callback never called. I am using your last checked in code (with 1.1 API changes).

Please suggest require code changes.


Sep 10, 2012 at 3:58 PM


I've only worked on the REST API so far and haven't done any testing on Streams to see if they work with the new v1.1 endpoints yet.

There are a couple options here: (1) set the UserStreamUrl property of TwitterContext to the previous base url: or (2) use the v1.0 libraries until I finish the conversion.


Sep 10, 2012 at 4:31 PM

I already tried both option, still same issue :(

Sep 30, 2012 at 6:44 AM

Found a fix for this and checked it in.


Sep 30, 2012 at 6:19 PM

Thanks joe will check. One more question.. linq2twitter fully gzipped?

Sep 30, 2012 at 6:51 PM

The client rest api supports gzip.  However, the windows phone profile and streams don't have it yet.  I added a new issue to support it.


Oct 4, 2012 at 4:46 AM

Thanks Joe