GTS
GTS

Reputation: 107

Access files from project folder in UWP

in my solution I have backgroundtask project which has a "Resources" directory. How can I acess the files of this directory?

I already tried

auto loader = Windows::ApplicationModel::Resources::ResourceLoader::GetForViewIndependentUse();

and I get a "ResourceMap Not Found" error.

Upvotes: 0

Views: 535

Answers (1)

Vittorio Vaselli
Vittorio Vaselli

Reputation: 141

Windows::ApplicationModel::Package^ package = Windows::ApplicationModel::Package::Current;
Windows::Storage::StorageFolder^ installedLocation = package->InstalledLocation;

this should return the Folder of your project that contains your "Resources" folder.

Upvotes: 1

Related Questions