Object reference not set to an instance of an object.

Jun 7, 2011 at 1:24 PM

   
Hi.

I have two facebook ids. i m able to connect with one id which is old one and have read/publish stream permission,
but with second id, i m getting the following error. even i m not getting facebook permissions at the time of login,
anybody please suggest me how can i solve this problem.

Thanks in advance

Server Error in '/' Application.

Object reference not set to an instance of an object.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error: 

Line 530:            string xmlResponse;
Line 531:
Line 532:            using (System.IO.StreamReader streamReader = new StreamReader(webResponse.GetResponseStream()))
Line 533:            {
Line 534:                xmlResponse = streamReader.ReadToEnd();


Source File: E:\Dev\FacebookSource\Facebook\Rest\RestBase.cs    Line: 532 

Stack Trace: 

[NullReferenceException: Object reference not set to an instance of an object.]
   Facebook.Rest.RestBase.processResponse(WebResponse webResponse, Boolean useJson) in E:\Dev\FacebookSource\Facebook\Rest\RestBase.cs:532
   Facebook.Rest.RestBase.SendRequestSynchronous(IDictionary`2 parameterDictionary, Boolean useSession, Boolean useJson) in E:\Dev\FacebookSource\Facebook\Rest\RestBase.cs:975
   Facebook.Rest.RestBase.SendRequest(IDictionary`2 parameterDictionary, Boolean useSession, Boolean useJson) in E:\Dev\FacebookSource\Facebook\Rest\RestBase.cs:150
   Facebook.Rest.RestBase.SendRequest(IDictionary`2 parameterDictionary, Boolean useSession) in E:\Dev\FacebookSource\Facebook\Rest\RestBase.cs:138
   Facebook.Rest.Stream.Get(Int64 viewer_id, List`1 source_ids, Nullable`1 start_time, Nullable`1 end_time, Nullable`1 limit, String filter_key, Boolean isAsync, GetCallback callback, Object state) in E:\Dev\FacebookSource\Facebook\Rest\Stream.cs:900
   Facebook.Rest.Stream.Get(Int64 viewerId, List`1 sourceIds, Nullable`1 startTime, Nullable`1 endTime, Nullable`1 limit, String filter_key) in E:\Dev\FacebookSource\Facebook\Rest\Stream.cs:140
   Facebook.Rest.Stream.Get(List`1 sourceIds, Nullable`1 startTime, Nullable`1 endTime, Nullable`1 limit) in E:\Dev\FacebookSource\Facebook\Rest\Stream.cs:119
   SocialMedia.Fbook._Default.Page_Load(Object sender, EventArgs e) in d:\SciGladsSourceCode\Dev\i3classWAP\SciGlads.Main\SciGlads.UI\SocialMedia\i3FBook\Default.aspx.cs:219
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
   System.Web.UI.Control.OnLoad(EventArgs e) +91
   System.Web.UI.Control.LoadRecursive() +74
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2207



Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1