views:

27

answers:

2

I am making an example app of a game. I have a folder i set as the current directory from within visual studios which includes pngs,ogg,config.json,etc.

When i 'publish' these files are not included. How do i properly add a media files/folders into the project?

+1  A: 

You right click on the files you need, select Properties and set the Copy To Output Directory setting to either Copy Always or Copy if Newer.

This will make sure they are "published".

Oded
cool. Is there a way to add a folder instead of dozens and dozens of files?
acidzombie24
hmm, i can add an ./resource folder and change my directory in main(). this solution looks fine.
acidzombie24
i also set built action to content
acidzombie24
+1  A: 

In Visual Studio, select all files you wish to be published (could be all files in a folder) using shift-click. Then right-click the list of selected files and choose properties. Set the Build Action to 'Content' and Copy to Output Directory to 'Copy always' (or 'Copy if newer')

edosoft
i also set built action to content
acidzombie24