Vasu Gadhiya

Vasu Gadhiya

  • NA
  • 429
  • 102.7k

How to add more image in project.

Oct 30 2013 6:34 AM
Hello

I Write Code for use image in project.

object O = MyPro.Properties.Resources.ResourceManager.GetObject("img_1");
Picturebox1.Image = (Image)O;


--------------------------------------------------------------------------------------

Its Work Completely But i want to use More image in Project (15000 images) So i add all images but after Project can't Build.
Error - There are no enough space to write metadata.

So i nee other way to add more image in project.


Any Other Way to add more image in project ??
--------------------------------------------------------------------------------------
Also i try Class Library but  its always return null.

Assembly _assembly = Assembly.LoadFile(@"H:\MyPro\Master\bin\Debug\ClassLibrary1.dll");
Stream _imageStream;
_assembly = Assembly.GetExecutingAssembly();
_imageStream = _assembly.GetManifestResourceStream("img_1");
pictureBox1.Image = new Bitmap(_imageStream);
--------------------------------------------------------------------------------------
I need other way that i can add more images in other project and can use in main project.

Thanks in advance.






Answers (2)