3

I recently tried making the jump from CefSharp 1.25.7 to the most recent build (39.0.0-pre02). I got the files through NuGet but I copied them into my project separately since they have to be included in our repository to share with other developers. I believe I got all of the files (even got the new icudtl.dat file that seems to replace icudt.dll).

I was able to get all of the API changes resolved and added the new files and such. It builds and all of the dlls seem to be resolved but for some reason Cef.Initialize() (with and without settings) always fails. There are no errors in my output window or anything, just a false return. Any suggestions as to where I should be looking for the problem? I'm running VS2010, which I know had some issues building from source but I thought that using the binaries would get around that.

zaknotzach
  • 977
  • 1
  • 9
  • 18

1 Answers1

3

Sounds like you could be missing e.g. the CefSharp.BrowserSubprocess.exe and its dependent dlls in your bin/ folder. After Cef.Initialize() you should see that process spawned if you look in Windows Task manager. It's similar to all the Chrome.exe processes "That Google product variant" launches.

Compared to CefSharp 1 it's a quite different multiprocess beast under the hood. See https://github.com/cefsharp/CefSharp/wiki/Versions and it's pointer to the nice upstream CEF project documentation.

To quickly/more safely get off the ground use the CefSharp.MinimalExample repo as your reference. Its NuGet use should take care of copying all relevant files to your bin/ folder. Make sure your NuGet install in VS2010 is up to date.

jornh
  • 1,369
  • 13
  • 27
  • Thanks! I think I had all of the DLLs but forgot `CefSharp.BrowserSubprocess.exe`. The odd thing is that it still fails initialize but the browser seems to work and pages show up... Also it seems like the default scrollbars are very red. Any idea why/how to change that? – zaknotzach Feb 18 '15 at 15:20
  • 1
    Ah figured out the red scrollbars, I was missing the `.pak` files (I thought that was just a NuGetey thing... Still curious how it can fail initialize but still work though. – zaknotzach Feb 18 '15 at 15:54
  • :-) The NuGetey ones are "nup-kegs" `.nupkg` ... Chrom[e|ium] and CEF'ey ones are `.pak` files. And apparently some time in the start of rev 30-something with CEF the red scrollbars etc. started showing up with `DisablePackLoading` ... I'll go and nuke a few references to the option now as it creates more annoyance than light-weightness nowadays. Starting with the CefSharp FAQ. – jornh Feb 18 '15 at 16:19