Searchโ€ฆ
.NET Standard

Introduction

Before integrating a new BugSplat SDK with your application, make sure to review the Getting Started resources and complete the simple startup tasks listed below.
    โ€‹Sign up for a BugSplat account
    โ€‹Log in using your email address
    Create a new database for your application
Need any further help? Check out the full BugSplat documentation here, or email the team at [email protected].

Overview

BugSplatDotNetStandard allows you to capture and track exceptions on all .NET Standard 2.0 platforms. This includes:
    .NET Core
    Universal Windows Platform (UWP)
    Xamarin
    Mono

Configuration

Install the BugSplatDotNetStandard. NuGet package.
1
Install-Package BugSplatDotNetStandard
Copied!
After you've installed the NuGet package, add a using statement for the BugSplatDotNetStandard namespace.
1
using BugSplatDotNetStandard;
Copied!
Create a new instance of BugSplat providing it your database, application, and version. It's best to do this at the entry point of your application. Several defaults can be provided to BugSplat. You can provide default values for things such as description, email, key, user and file attachments.
1
var bugsplat = new BugSplat(database, application, version);
2
bugsplat.Attachments.Add(new FileInfo("/path/to/attachment.txt"));
3
bugsplat.Description = "the default description";
4
bugsplat.Email = "[email protected]";
5
bugsplat.Key = "the key!";
6
bugsplat.User = "Fred";
Copied!
The Post method can be used to send Exception objects to BugSplat.
1
try
2
{
3
throw new Exception("BugSplat rocks!");
4
}
5
catch(Exception ex)
6
{
7
await bugsplat.Post(exception);
8
}
Copied!
Additionally, Post can be used to upload minidumps to BugSplat.
1
await bugsplat.Post(new FileInfo("/path/to/minidump.dmp"));
Copied!
The default values for description, email, key and user can be overridden in the call to Post. Additional attachments can also be specified in the call to Post. Please note that the total size of the Post body and all attachments is limited to 2MB by default.
1
var options = new ExceptionPostOptions()
2
{
3
Description = "BugSplat rocks!",
4
Email = "[email protected]",
5
User = "Fred",
6
Key = "the key!"
7
};
8
options.AdditionalAttachments.Add(new FileInfo("/path/to/attachment2.txt"));
9
โ€‹
10
await bugsplat.Post(ex, options);
Copied!
Once you've generated an error, navigate to the BugSplat Dashboard and ensure you have to correct database selected in the dropdown menu. You should see a new crash report under the Recent Crashes section:
BugSplat Dashboard
Click the link in the ID column to see details about the crash:
.NET Standard Crash
Thatโ€™s it! Your application is now configured to post crash reports to BugSplat.
If you have any additional questions please reach out to our support team
Last modified 1mo ago