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


Loading local credentials error (version WinRt


This code from example work fine with version of linq to twittee it referenced to (version 2.0.8)

PinAuthorizer auth =
            new PinAuthorizer
                Credentials = new LocalDataCredentials()

        if (auth == null || !auth.IsAuthorized)

        var twitterCtx = new TwitterContext(auth);

        var timelineResponse =
                (from tweet in twitterCtx.Status
                 where tweet.Type == StatusType.Home
                 select tweet)
But if I use version I have async loading my local credentials and I in runtime am getting into

"if (auth == null || !auth.IsAuthorized)"
before credentials loaded completely so auth is not authorized.
When I set breakpoint in debug everything works fine and auth - object has
completely loaded credentials (loading operation finishes in background because of time delay).

Can you help me how can I walk around this problem using version in WinRT, thanks
Closed Jan 20, 2013 at 12:40 AM by JoeMayo


ramezdebbas wrote Oct 22, 2012 at 7:06 PM

I got that problem too, so basically every time I load my app, it keeps asking the user to login.

Any solution for that .


JoeMayo wrote Oct 28, 2012 at 1:33 AM

The work-around for this is to use WinRtAuthorizer. There's a project in the Samples page called MetroWinRtAuthorizer: