Import Swift Libraries

Hello,
How can I import swift libraries in visual studio 2017? When I used a sandbox online I could import libraries by typing “import Foundation” and “import Glibc.”

Now when I try to import the libraries, it says “Unknown Namespace.”

How can I fix this?
Thank You

What platform is your project for? Foundation is a Cocoa library, and only available on Cocoa projects.

Does that mean that I need a Mac in order to use the foundation library?

Nof per se. It means Foundation, being a library of Apple’s operating system, will only be available when you create a project for macOS (or iOS/tvOS/watchOS).

Silver supports creating applications for many different platforms, .NET, Java/Android, Cocoa and more. On each platform, you can use the native libraries of that platform. Check out this blog post for four more details on this: Platform vs. Language

hth,
marc