You are developing a Windows Store app. The app consumes data from a popular social
networking site. The requestUri variable represents the address of the social networking site.
The code contains an error.
You need to identify the cause of the error.
You have the following code. (Line numbers are included for reference only.)
Which line of code should you identify?
A.
line 02
B.
line 04
C.
line 09
D.
line 13
https://code.msdn.microsoft.com/windowsapps/Web-Authentication-d0485122
WebAuthenticationResult WebAuthenticationResult = await WebAuthenticationBroker.AuthenticateAsync(WebAuthenticationOptions.None, StartUri, EndUri);
if (WebAuthenticationResult.ResponseStatus == WebAuthenticationStatus.Success)
{
OutputToken(WebAuthenticationResult.ResponseData.ToString());
await GetFacebookUserNameAsync(WebAuthenticationResult.ResponseData.ToString());
}
else if (WebAuthenticationResult.ResponseStatus == WebAuthenticationStatus.ErrorHttp)
{
OutputToken(“HTTP Error returned by AuthenticateAsync() : ” + WebAuthenticationResult.ResponseErrorDetail.ToString());
}
else
{
OutputToken(“Error returned by AuthenticateAsync() : ” + WebAuthenticationResult.ResponseStatus.ToString());
}
line 04:
auth.Completed = delegate (IAsyncOperation asyncAction, AsyncStatus asyncStatus)
04 auth.Completed = delegate (IAsyncOperation<WebAuthenticationResult> asyncAction, AsyncStatus asyncStatus)
Line 04 should be “auth.Completed += delegate…”