Sure, you can use the API version of MakeSureDirectoryPathExists function to satisfy your needs, but here is an alternative way.
Latest Folder/Directory Maintenance Articles - Page 2
This piece of code will delete a folder that isn't empty in Windows NT or Windows 2000.
Function that takes a full path and walks that string creating each folder until all are created
Useful Win32 API-based function that deletes all folders and files within a specified folder
Single function to create multiple levels of folders
Latest CodeGuru Developer Columns
Learn more about a few commonly used components and explore their utility and usages.
Master using the EF core with a version available that is specifically designed for use with the .NET Core.
Studying this article will help you fully understand Visual Basic and .NET data types.