By default, each Browser instance stores all user data such as history, cookies, cache on disk. Since 1.14 you can configure Browser instance to store all user data in memory (Chromium's "Incognito" mode), so that all user data will be cleared once your .Net application is terminated.


The following example demonstrates how to configure Browser instance to work in "Incognito" mode and store all user data in memory:

using System.Windows.Forms;
using DotNetBrowser;
using DotNetBrowser.WinForms;

namespace WindowsFormsApplication9
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
            BrowserContextParams parameters = new BrowserContextParams("data-dir") { StorageType = StorageType.MEMORY };
            BrowserContext context = new BrowserContext(parameters);
            Browser browser = BrowserFactory.Create(context);
            WinFormsBrowserView browserView = new WinFormsBrowserView(browser);
            browser.LoadURL("teamdev.com");

            Controls.Add(browserView);
        }
    }
}