Hello! I sought solutions to my problem here and elsewhere and did nothing. Codes and more codes to reduce memory and nothing ...
I'm a beginner on programming and do not fix my mistakes, we're here to learn :) My problem is this: I have a VB application with listbox listing multiple items. Each selected item loads a certain text for some labels (to describe the item) and loads an image for a picturebox (each image is different) There are over 1000 images all loaded from 2 DLLs. In the database.vb file I created several cases. Each item selected in the listbox calls the corresponding image. EX database.vb:
Case "Fulano"
programa.idade.Text = "18" 'texto
programa.picture.Image = dll.imgs.Fulano 'imagem
What happens is that when I compile, I click on any item in the listbox the program stops for 2 or 3 seconds (loading all the images) and the memory usage changes to more than 500mb. So the program works normally however with the gigantic use of memory ...
I know I could have created a database. But I do not know how and I do not know if it would help What would be the best solution for my case? Can you make it load image by image?
Maybe create a database for images only? Create a memory dump in HD?
* PS: Ideally, the user should not have access to the images outside the program