You can use Assembly.GetManifestResourceStream(resource_name_of_the_file) to access the file stream, write it to the TEMP directory, and use this path.
For example, if you have a file in your project on the path " Resources \ Files \ .txt File " and the default namespace for the project assembly is RootNamespace ", you can access the file stream from this assembly code using
Assembly.GetExecutingAssembly().GetManifestResourceStream("RootNamespace.Resources.Files.File.txt")
source share