To solve this problem in visual studio code, in debugging select the option Attach to .NET Functions as shown in following image.
Attach to .NET Functions