Main Site Documentation

Resources.Getbytes() is gone!


#1

I was looking into some examples that uses “Resources.Getbytes()”

Getbytes() is meanwhile gone…

Does anyone knows what to do then?


#2

Bitmap bmp = Resources.GetBitmap(Resources.BitmapResources.Smiley);
byte[] buffer = bmp.GetBitmap();


#3

You add a resource file (if you don’t already have one) to your project and then add a binary resource before this function ‘appears’. Strange, but true!


#4

It is auto generated method. You can look at how it is implemented in Resources.Designer.cs (after adding a binary resource)