litachugga
You can find out what error is being caught by looking at the Exception error message.
Change your catch block to this and run in debug, the error message will appear in the VStudio "output" window
( the return of null is from your catch block of code )
You can find out what error is being caught by looking at the Exception error message.
Change your catch block to this and run in debug, the error message will appear in the VStudio "output" window
( the return of null is from your catch block of code )
Code:
catch (Exception ex)
{
Console.WriteLine(ex.Message);
return null;
}


Comment