0

Hello I'm writing Windows phone application for working with OneDrive. My code is pretty simple: XAML:

<OneDrive:SignInButton Name="signInButton1"
                       Height="72"
                       Margin="152,436,144,0"
                       VerticalAlignment="Top"
                       ClientId="MYCLIENTID"
                       Scopes="wl.basic wl.photos wl.skydrive wl.offline_access wl.signin wl.skydrive_update"
                       SessionChanged="signInButton1_SessionChanged"
                       TextType="Custom" />

CS code:

private void signInButton1_SessionChanged(object sender, Microsoft.Live.Controls.LiveConnectSessionChangedEventArgs e)
{
    if (e.Session != null && e.Status == LiveConnectSessionStatus.Connected)
    {
        Session = e.Session;
    }
}

When I push drive sign in button Signin the window is opened and if i don't submit this window but instead just press the back button then the white screen is shown and I get:

An exception of type 'Microsoft.Live.LiveAuthException' occurred in mscorlib.ni.dll and wasn't handled before a managed/native boundary
User has not granted the application consent to access data in Windows Live

Could somebody help me with it?

Johan Falk
  • 4,341
  • 2
  • 30
  • 42
Vovich
  • 321
  • 1
  • 3
  • 13

1 Answers1

0

Try upgrading to the LiveSDK 5.6, which was just released a week or two ago. In using a sample Windows Phone 8 app with your code, this exception appears to be handled internally and doesn't get thrown into the UI (aka, I can't repro this with Live SDK 5.6).

Ryan Gregg
  • 2,015
  • 13
  • 16