|
-
VB.NET 2008 Get resource file as IO.Stream
I am developing a VB.NET 2008 application, consisting of a main EXE application and several resource DLLs.
I need two functions for the DLL:
1) one function to get a list of all files in the resources of the DLL.
2) one function to return 'by name' a resource file as a System.IO.Stream type.
NOTE: The files will not be "Embedded Resource" (this doubles the size of the DLL), so I think cannot use 'GetManifestResourceStream'.
I currently use:
Return New System.IO.MemoryStream(My.Resources.MyFileName)
but I want it to be called by name.
I am adding the resources using the VS 2008 "Resources" tab, from the My Project screen, I'm not manually editing Resources.resx
As I said before, it works with:
Return New System.IO.MemoryStream(My.Resources.MyFileName)
but I need to get the resources by name, which also works by using
GetMAnifestResourceStream
but this requires to set the resources Build Action to "Embedded Resource", which doubles the size of my DLL file.
I currently use "None" as Build Action, but I can use any Build Action that does not increase the file size more than the actual resources size.
Thank you in advance.
Similar Threads
-
Replies: 1
Last Post: 03-20-2008, 02:04 AM
-
By software_develo in forum .NET
Replies: 1
Last Post: 01-25-2006, 12:12 PM
-
By khackbarth in forum VB Classic
Replies: 2
Last Post: 05-04-2005, 06:26 PM
-
By jase_dukerider in forum C++
Replies: 2
Last Post: 04-14-2005, 07:48 PM
-
By Andrew McLellan in forum Java
Replies: 3
Last Post: 05-09-2001, 05:34 PM
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks