Link to home
Start Free TrialLog in
Avatar of rocky050371
rocky050371

asked on

Resources Folder

I have added three resource files into my project, I have a control that requires the full path to these files (so I cant use my.resources). When I distribute the project is there a standard place to put the resources folder ie under the application root. What I want to happen is that if I code the filename it stays the same when distributed. Any ideas
Avatar of Bob Learned
Bob Learned
Flag of United States of America image

If you included resources into your project, and then set the build action to 'Embedded Resource', then you can use them without having to have a folder on the destination drive.

Bob
Avatar of rocky050371
rocky050371

ASKER

But I need to provide the control with a relative path to the file
For 2005, there is the App_GlobalResources and App_LocalResources folder, if you are using ASP.NET.  If you aren't, then you can name the folder anything reasonable, like Resources.

Bob
I take it I set there path to a temp directory then when I release it set it to Application Path\Resources
You can use the Resources folder under the \bin\Debug folder during development to have the same folder structure.

Bob
Thank you, is the correct way to use the application.path method
ASKER CERTIFIED SOLUTION
Avatar of Bob Learned
Bob Learned
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial