Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


Don't forget to read Tuesday's email newsletter for your chance to win a free copy of Construct 2!


[.net] C# Properties.Resources


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
3 replies to this topic

#1 Zekk   Members   -  Reputation: 122

Like
0Likes
Like

Posted 05 April 2009 - 07:00 AM

to load a mp3 file I can do ; string locName = "atb.mp3"; windowsMediaPlayer.URL = locName; but if I want to add the mp3 as a resource I cant do: string locName = Properties.Resources.atb; how would I load the file from resources I dragged it over to audio but it doesn't seem to work.

Sponsor:

#2 Zekk   Members   -  Reputation: 122

Like
0Likes
Like

Posted 09 April 2009 - 07:13 PM

bump any ideas on perhaps another method to load mp3 from resources

#3 mutex   Members   -  Reputation: 1109

Like
0Likes
Like

Posted 09 April 2009 - 09:16 PM

IIRC those resources are embedded within the .exe itself, and so you'll need to extract them to files so that you can generate a URL to them.

It's probably easiest to not use Properties.Resources for MP3s in the first place, and instead keep them as loose files.

#4 Mike.Popoloski   Crossbones+   -  Reputation: 2923

Like
0Likes
Like

Posted 10 April 2009 - 04:02 AM

GetManifestResourceStream might help.
Mike Popoloski | Journal | SlimDX




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS