Page 1 of 1

Different cache directories id dcef4

Posted: Sat Mar 13, 2021 12:34 am
by mihmih8
Hello!

How can I use different cache folders?
For example:

Press button1 -> GlobalCEFApp.cache := 'C:\Cache\1\'; -> Chromium1.LoadURL(url);
Press button2 -> GlobalCEFApp.cache := 'C:\Cache\2\'; -> Chromium1.LoadURL(url);

In the cef3 , you could CookieManager.SetStoragePath(CookiesPath); But in the dcef4, it doesn't work that way...

Re: Different cache directories id dcef4

Posted: Sat Mar 13, 2021 9:05 am
by salvadordf
Hi,

The SetStoragePath function was removed from the CEF API.

You need to use a new request context for new browsers. Each new request context is independent from the rest and you can use a different cache directory.

See the MDIBrowser demo for all the details.